projects
/
php
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b6feabc
)
- Fixed possible NULL ptr dereference
author
Felipe Pena
<felipensp@gmail.com>
Sun, 20 Oct 2013 11:04:24 +0000
(09:04 -0200)
committer
Felipe Pena
<felipensp@gmail.com>
Sun, 20 Oct 2013 11:04:24 +0000
(09:04 -0200)
ext/phar/util.c
patch
|
blob
|
history
diff --git
a/ext/phar/util.c
b/ext/phar/util.c
index 898d8bd4b2146e3b92b759c3d8f667ea0a8cccda..227bd15dc715c9963970329f9c06464903a8e776 100644
(file)
--- a/
ext/phar/util.c
+++ b/
ext/phar/util.c
@@
-1262,8
+1262,10
@@
alias_success:
spprintf(error, 0, "alias \"%s\" is already used for archive \"%s\" cannot be overloaded with \"%s\"", alias, (*fd_ptr)->fname, fname);
}
if (SUCCESS == phar_free_alias(*fd_ptr, alias, alias_len TSRMLS_CC)) {
- efree(*error);
- *error = NULL;
+ if (error) {
+ efree(*error);
+ *error = NULL;
+ }
}
return FAILURE;
}