projects
/
m6w6
/
ext-http
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
| inline |
side by side
* fix memleak
[m6w6/ext-http]
/
http_api.c
diff --git
a/http_api.c
b/http_api.c
index 20dc30da8d2629770946254ce5282c62562d66b1..2b3e33c7d57fbc400aaf41d260d3111ecbbeb2c7 100644
(file)
--- a/
http_api.c
+++ b/
http_api.c
@@
-1093,9
+1093,12
@@
PHP_HTTP_API char *_http_negotiate_q(const char *entry, const HashTable *support
FOREACH_HASH_KEY(Z_ARRVAL(zentries), key, idx) {
if (key) {
- return estrdup(key);
+ key = estrdup(key);
+ zval_dtor(&zentries);
+ return key;
}
}
+ zval_dtor(&zentries);
return estrdup(def);
}