X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=php5-swig%2Fxml-template.swig;h=d395ac20a72cc097ed7335b8dde68b7f6af1776a;hb=b6bae3e8cf33edf6bbedcf6d3266e581d06507af;hp=5a560cee6883bf4bce903964fe653ee2755a71c5;hpb=dc9c34267800f553307ee41acf40cb14929385ba;p=xml-template diff --git a/php5-swig/xml-template.swig b/php5-swig/xml-template.swig index 5a560ce..d395ac2 100644 --- a/php5-swig/xml-template.swig +++ b/php5-swig/xml-template.swig @@ -10,9 +10,7 @@ bool is_associative_array(HashTable *ht) return true; } for (unsigned i = 0; i < ht->nNumOfElements; ++i) { - char buf[32]; - sprintf(buf, "%u", i); - if (!zend_hash_exists(ht, buf, strlen(buf))) { + if (!zend_hash_index_exists(ht, i)) { return true; } }