From b75f2df3d433d9d4fb795a1ce131d54aebeef3f6 Mon Sep 17 00:00:00 2001 From: Moriyoshi Koizumi Date: Mon, 18 Nov 2002 21:20:45 +0000 Subject: [PATCH] We have to use binary mode here. --- ext/mime_magic/mime_magic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/ext/mime_magic/mime_magic.c b/ext/mime_magic/mime_magic.c index f37eb4726c..a370839a66 100644 --- a/ext/mime_magic/mime_magic.c +++ b/ext/mime_magic/mime_magic.c @@ -982,7 +982,7 @@ static int magic_process(char *filename TSRMLS_DC) return result; } - stream = php_stream_open_wrapper(filename, "r", IGNORE_PATH | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL); + stream = php_stream_open_wrapper(filename, "rb", IGNORE_PATH | ENFORCE_SAFE_MODE | REPORT_ERRORS, NULL); if (stream == NULL) { /* We can't open it, but we were able to stat it. */ -- 2.40.0