diff options
author | Haibo Huang <hhb@google.com> | 2019-10-08 15:48:26 -0700 |
---|---|---|
committer | Haibo Huang <hhb@google.com> | 2019-11-14 22:14:23 +0000 |
commit | 80b4251e302efb18c145a4786249d695397ed42a (patch) | |
tree | 12b9dec2513f7caa92e7835bc17ab16ae5635df6 /Lib/php/globalvar.i | |
parent | 189852d8cdfd5863c52ec7aa73affd926c5a3f43 (diff) | |
parent | 1e36f51346d95f8b9848e682c2eb986e9cb9b4f4 (diff) | |
download | swig-80b4251e302efb18c145a4786249d695397ed42a.tar.gz |
Upgrade swig to 'rel-4.0.1'llvm-r383902b
Also run autogen.sh to generate configure files.
Exempt-From-Owner-Approval: add myself to owners
Change-Id: I391aa20428836ae74dab8c8427627ca4dbc8ecf4
Diffstat (limited to 'Lib/php/globalvar.i')
-rw-r--r-- | Lib/php/globalvar.i | 23 |
1 files changed, 11 insertions, 12 deletions
diff --git a/Lib/php/globalvar.i b/Lib/php/globalvar.i index a5fd779ab..6b31207a6 100644 --- a/Lib/php/globalvar.i +++ b/Lib/php/globalvar.i @@ -136,7 +136,7 @@ %typemap(varin) SWIGTYPE [] { - if($1) { + if ($1) { zval *z_var = zend_hash_str_find(&EG(symbol_table), "$1", sizeof("$1") - 1); SWIG_SetPointerZval(z_var, (void*)$1, $1_descriptor, $owner); } @@ -144,15 +144,15 @@ %typemap(varin) char [ANY] { - zval **z_var; - char *s1; - - zend_hash_str_find(&EG(symbol_table), "$1", sizeof("$1") - 1, (void**)&z_var); - s1 = Z_STRVAL_P(z_var); - if ((s1 == NULL) || ($1 == NULL) || strcmp(s1, $1)) { - if (s1) - strncpy($1, s1, $1_dim0); - } + zval **z_var; + char *s1; + + zend_hash_str_find(&EG(symbol_table), "$1", sizeof("$1") - 1, (void**)&z_var); + s1 = Z_STRVAL_P(z_var); + if ((s1 == NULL) || ($1 == NULL) || strcmp(s1, $1)) { + if (s1) + strncpy($1, s1, $1_dim0); + } } %typemap(varin) SWIGTYPE @@ -166,7 +166,6 @@ } $1 = *($&1_ltype)_temp; - } %typemap(varin) SWIGTYPE *, SWIGTYPE &, SWIGTYPE && @@ -245,7 +244,7 @@ (z_var)->value.str.val = 0; (z_var)->value.str.len = 0; } - } + } } %typemap(varout) SWIGTYPE |