projects
/
php
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
25d327e
)
Fixed invalid read (Part issue of #69579)
author
Xinchen Hui
<laruence@php.net>
Fri, 10 Jul 2015 14:26:53 +0000
(22:26 +0800)
committer
Xinchen Hui
<laruence@php.net>
Fri, 10 Jul 2015 14:26:53 +0000
(22:26 +0800)
Zend/zend_inheritance.c
patch
|
blob
|
history
diff --git
a/Zend/zend_inheritance.c
b/Zend/zend_inheritance.c
index 4bd7eb9c762403276f23be3b5aec4cf8d30cb4ad..c794c969c0ab2722288950df28cbfbfa43c3a2fc 100644
(file)
--- a/
Zend/zend_inheritance.c
+++ b/
Zend/zend_inheritance.c
@@
-1200,7
+1200,8
@@
static int zend_traits_copy_functions(zend_string *fnname, zend_function *fn, ze
if (exclude_table == NULL || zend_hash_find(exclude_table, fnname) == NULL) {
/* is not in hashtable, thus, function is not to be excluded */
- fn_copy = *fn;
+ /* And how about ZEND_OVERLOADED_FUNCTION? */
+ memcpy(&fn_copy, fn, fn->type == ZEND_USER_FUNCTION? sizeof(zend_op_array) : sizeof(zend_internal_function));
/* apply aliases which have not alias name, just setting visibility */
if (ce->trait_aliases) {