Files
conan-build/recipes/m4/all/patches/1.4.18-0008-open-files-in-binary-mode.patch
2024-12-26 12:02:17 +03:00

16 lines
371 B
Diff

This will open all files in binary mode.
files may contain binary data.
This fixes e.g. autoconf, of whose frozen file, contains all characters from 0x00 to 0xff.
--- src/path.c
+++ src/path.c
@@ -110,7 +110,7 @@
static FILE *
m4_fopen (const char *file)
{
- FILE *fp = fopen (file, "r");
+ FILE *fp = fopen (file, "rb");
if (fp)
{
struct stat st;