Skip to content

Commit cee9722

Browse files
dstogovsmalyshev
authored andcommitted
Fixed recently introduced memory leak
1 parent 9af582b commit cee9722

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

ext/phar/phar.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1113,6 +1113,7 @@ static int phar_parse_pharfile(php_stream *fp, char *fname, int fname_len, char
11131113
entry.metadata_len = 0;
11141114
}
11151115
if (len > endbuffer - buffer) {
1116+
pefree(entry.filename, entry.is_persistent);
11161117
MAPPHAR_FAIL("internal corruption of phar \"%s\" (truncated manifest entry)");
11171118
}
11181119
if (phar_parse_metadata(&buffer, &entry.metadata, len TSRMLS_CC) == FAILURE) {

0 commit comments

Comments
 (0)