projects
/
web/konrad/twig.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
(parent:
1e726f4
)
Fixed TWIG_PROPERTY to return a NULL instead of a zval(NULL).
author
Derick Rethans
<github@derickrethans.nl>
Thu, 7 Jul 2011 14:43:13 +0000 (15:43 +0100)
committer
Derick Rethans
<github@derickrethans.nl>
Thu, 7 Jul 2011 14:43:13 +0000 (15:43 +0100)
twig.c
patch
|
blob
|
history
diff --git
a/twig.c
b/twig.c
index
acbae38
..
26ef899
100644
(file)
--- a/
twig.c
+++ b/
twig.c
@@
-328,9
+328,14
@@
zval *TWIG_PROPERTY(zval *object, zval *propname)
}
if (Z_OBJ_HT_P(object)->read_property) {
- tmp = Z_OBJ_HT_P(object)->read_property(object, propname, BP_VAR_R TSRMLS_CC);
- return tmp;
+ tmp = Z_OBJ_HT_P(object)->read_property(object, propname, BP_VAR_IS TSRMLS_CC);
+ if (&tmp != &EG(uninitialized_zval_ptr)) {
+ return tmp;
+ } else {
+ return NULL;
+ }
}
+ return tmp;
}
zval *TWIG_PROPERTY_CHAR(zval *object, char *propname)