Skip to content

Commit 9d77bf0

Browse files
committed
Fix regex
1 parent 60adea5 commit 9d77bf0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ext/fileinfo/libmagic/softmagic.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,7 @@ check_fmt(struct magic_set *ms, struct magic *m)
421421
return 0;
422422

423423
(void)setlocale(LC_CTYPE, "C");
424-
pattern = zend_string_init("~%[-0-9.]*s~", sizeof("~%[-0-9.]*s~") - 1, 0);
424+
pattern = zend_string_init("~%[-0-9\\.]*s~", sizeof("~%[-0-9\\.]*s~") - 1, 0);
425425
if ((pce = pcre_get_compiled_regex(pattern, &re_extra, &re_options)) == NULL) {
426426
rv = -1;
427427
} else {

0 commit comments

Comments
 (0)