summaryrefslogtreecommitdiff
path: root/zend/super.cpp
diff options
context:
space:
mode:
authorMartijn Otto <martijn.otto@copernica.com>2016-05-17 13:47:20 +0200
committerMartijn Otto <martijn.otto@copernica.com>2016-05-17 13:47:20 +0200
commitdd5f3a635053aa03417cdab1228e03c94b9c3136 (patch)
tree53178a459fcefdfa551eb501064e70453611788a /zend/super.cpp
parent9f2e816c787c30ceeb139623c8dae594c4b4443d (diff)
Fixed final compilation issues
Diffstat (limited to 'zend/super.cpp')
-rw-r--r--zend/super.cpp12
1 files changed, 9 insertions, 3 deletions
diff --git a/zend/super.cpp b/zend/super.cpp
index ea690fe..02a1e46 100644
--- a/zend/super.cpp
+++ b/zend/super.cpp
@@ -32,10 +32,16 @@ Value Super::value()
TSRMLS_FETCH();
// call zend_is_auto_global to ensure that the just-in-time globals are loaded
- if (_name) { zend_is_auto_global(_name, ::strlen(_name) TSRMLS_CC); _name = nullptr; }
-
+ if (_name) {
+ // make the variable an auto global
+ zend_is_auto_global(zend_string_init(_name, ::strlen(_name), 1) TSRMLS_CC);
+
+ // reset because we only need to do this once
+ _name = nullptr;
+ }
+
// create a value object that wraps around the actual zval
- return Value(PG(http_globals)[_index]);
+ return &PG(http_globals)[_index];
}
/**