Browse Source

avoid Windows perform newline translation (#4128)

TianlongLiang 11 months ago
parent
commit
48a87dc8bf
1 changed files with 1 additions and 1 deletions
  1. 1 1
      test-tools/binarydump-tool/binarydump.c

+ 1 - 1
test-tools/binarydump-tool/binarydump.c

@@ -15,7 +15,7 @@ read_file_to_buffer(const char *filename, int *ret_size)
     FILE *file;
     int file_size, read_size;
 
-    if (!(file = fopen(filename, "r")))
+    if (!(file = fopen(filename, "rb")))
         return NULL;
 
     fseek(file, 0, SEEK_END);