--- php-5.4.5/Zend/zend_hash.c.interned_keys 2012-07-18 09:19:16.000000000 +0300 +++ php-5.4.5/Zend/zend_hash.c 2012-09-28 06:42:14.000000000 +0300 @@ -243,8 +243,8 @@ p = p->pNext; } - if (IS_INTERNED(arKey)) { - p = (Bucket *) pemalloc(sizeof(Bucket), ht->persistent); + if (!ht->persistent && IS_INTERNED(arKey)) { + p = (Bucket *) emalloc(sizeof(Bucket)); if (!p) { return FAILURE; } @@ -320,8 +320,8 @@ p = p->pNext; } - if (IS_INTERNED(arKey)) { - p = (Bucket *) pemalloc(sizeof(Bucket), ht->persistent); + if (!ht->persistent && IS_INTERNED(arKey)) { + p = (Bucket *) emalloc(sizeof(Bucket)); if (!p) { return FAILURE; } @@ -1360,8 +1360,8 @@ (!IS_INTERNED(p->arKey) && p->nKeyLength != str_length)) { Bucket *q; - if (IS_INTERNED(str_index)) { - q = (Bucket *) pemalloc(sizeof(Bucket), ht->persistent); + if (!ht->persistent && IS_INTERNED(str_index)) { + q = (Bucket *) emalloc(sizeof(Bucket)); } else { q = (Bucket *) pemalloc(sizeof(Bucket) + str_length, ht->persistent); } @@ -1400,7 +1400,7 @@ } else { p->h = h; p->nKeyLength = str_length; - if (IS_INTERNED(str_index)) { + if (!ht->persistent && IS_INTERNED(str_index)) { p->arKey = str_index; } else { p->arKey = (const char*)(p+1);