diff options
Diffstat (limited to 'ext/fileinfo/libmagic')
-rw-r--r-- | ext/fileinfo/libmagic/funcs.c | 6 | ||||
-rw-r--r-- | ext/fileinfo/libmagic/softmagic.c | 4 |
2 files changed, 5 insertions, 5 deletions
diff --git a/ext/fileinfo/libmagic/funcs.c b/ext/fileinfo/libmagic/funcs.c index ea89a679d0..6e12bf6338 100644 --- a/ext/fileinfo/libmagic/funcs.c +++ b/ext/fileinfo/libmagic/funcs.c @@ -56,13 +56,13 @@ FILE_RCSID("@(#)$File: funcs.c,v 1.94 2017/11/02 20:25:39 christos Exp $") # define PREG_OFFSET_CAPTURE (1<<8) #endif -extern public void convert_libmagic_pattern(zval *pattern, char *val, int len, int options); +extern public void convert_libmagic_pattern(zval *pattern, char *val, size_t len, uint32_t options); protected int file_printf(struct magic_set *ms, const char *fmt, ...) { va_list ap; - int len; + size_t len; char *buf = NULL, *newstr; va_start(ap, fmt); @@ -466,7 +466,7 @@ protected int file_replace(struct magic_set *ms, const char *pat, const char *rep) { zval patt; - int opts = 0; + uint32_t opts = 0; pcre_cache_entry *pce; zend_string *res; zend_string *repl; diff --git a/ext/fileinfo/libmagic/softmagic.c b/ext/fileinfo/libmagic/softmagic.c index 310f8611ee..d444115255 100644 --- a/ext/fileinfo/libmagic/softmagic.c +++ b/ext/fileinfo/libmagic/softmagic.c @@ -1829,7 +1829,7 @@ file_strncmp16(const char *a, const char *b, size_t len, uint32_t flags) } public void -convert_libmagic_pattern(zval *pattern, char *val, int len, int options) +convert_libmagic_pattern(zval *pattern, char *val, size_t len, uint32_t options) { int i, j=0; zend_string *t; @@ -2024,7 +2024,7 @@ magiccheck(struct magic_set *ms, struct magic *m) } case FILE_REGEX: { zval pattern; - int options = 0; + uint32_t options = 0; pcre_cache_entry *pce; options |= PCRE2_MULTILINE; |