json_dump_file: Open the output file in wb mode
[jansson.git] / src / dump.c
index d87d5c7..33112ba 100644 (file)
@@ -425,7 +425,7 @@ int json_dump_file(const json_t *json, const char *path, size_t flags)
 {
     int result;
 
-    FILE *output = fopen(path, "w");
+    FILE *output = fopen(path, "wb");
     if(!output)
         return -1;