Lines Matching refs:var_hash

113 	var_entries *var_hash = (*var_hashx)->last;
115 …fprintf(stderr, "var_push(" ZEND_LONG_FMT "): %d\n", var_hash?var_hash->used_slots:-1L, Z_TYPE_P(r…
118 if (var_hash->used_slots == VAR_ENTRIES_MAX) {
119 var_hash = emalloc(sizeof(var_entries));
120 var_hash->used_slots = 0;
121 var_hash->next = 0;
123 (*var_hashx)->last->next = var_hash;
124 (*var_hashx)->last = var_hash;
127 var_hash->data[var_hash->used_slots++] = rval;
143 var_dtor_entries *var_hash;
150 var_hash = (*var_hashx)->last_dtor;
151 if (!var_hash || var_hash->used_slots + num > VAR_DTOR_ENTRIES_MAX) {
152 var_hash = emalloc(sizeof(var_dtor_entries));
153 var_hash->used_slots = 0;
154 var_hash->next = 0;
157 (*var_hashx)->first_dtor = var_hash;
159 (*var_hashx)->last_dtor->next = var_hash;
162 (*var_hashx)->last_dtor = var_hash;
164 …for (used_slots = var_hash->used_slots; var_hash->used_slots < used_slots + num; var_hash->used_sl…
165 ZVAL_UNDEF(&var_hash->data[var_hash->used_slots]);
166 Z_EXTRA(var_hash->data[var_hash->used_slots]) = 0;
168 return &var_hash->data[used_slots];
179 var_entries *var_hash = &(*var_hashx)->entries;
181 …fprintf(stderr, "var_replace(" ZEND_LONG_FMT "): %d\n", var_hash?var_hash->used_slots:-1L, Z_TYPE_…
184 while (var_hash) {
185 for (i = 0; i < var_hash->used_slots; i++) {
186 if (var_hash->data[i] == ozval) {
187 var_hash->data[i] = nzval;
191 var_hash = var_hash->next;
197 var_entries *var_hash = &(*var_hashx)->entries;
199 …fprintf(stderr, "var_access(" ZEND_LONG_FMT "): " ZEND_LONG_FMT "\n", var_hash?var_hash->used_slot…
202 while (id >= VAR_ENTRIES_MAX && var_hash && var_hash->used_slots == VAR_ENTRIES_MAX) {
203 var_hash = var_hash->next;
207 if (!var_hash) return NULL;
209 if (id < 0 || id >= var_hash->used_slots) return NULL;
211 return var_hash->data[id];
218 var_entries *var_hash = (*var_hashx)->entries.next;
225 fprintf(stderr, "var_destroy( " ZEND_LONG_FMT ")\n", var_hash?var_hash->used_slots:-1L);
228 while (var_hash) {
229 next = var_hash->next;
230 efree_size(var_hash, sizeof(var_entries));
231 var_hash = next;
444 …TER zval *rval, const unsigned char **p, const unsigned char *max, php_unserialize_data_t *var_hash
445 #define UNSERIALIZE_PASSTHRU rval, p, max, var_hash
451 if (var_hash) {
452 if ((*var_hash)->max_depth > 0 && (*var_hash)->cur_depth >= (*var_hash)->max_depth) {
457 (*var_hash)->max_depth);
460 (*var_hash)->cur_depth++;
484 var_push_dtor(var_hash, old_data);
495 var_push_dtor(var_hash, old_data);
565 if ((*var_hash)->ref_props) {
568 (*var_hash)->ref_props, (zend_uintptr_t) old_data);
571 var_push_dtor(var_hash, old_data);
576 var_push_dtor(var_hash, old_data);
592 if (!php_var_unserialize_internal(data, p, max, var_hash, 0)) {
615 if (!(*var_hash)->ref_props) {
616 (*var_hash)->ref_props = emalloc(sizeof(HashTable));
617 zend_hash_init((*var_hash)->ref_props, 8, NULL, NULL, 0);
620 (*var_hash)->ref_props, (zend_uintptr_t) data, info);
625 var_push_dtor(var_hash, data);
635 if (var_hash) {
636 (*var_hash)->cur_depth--;
641 if (var_hash) {
642 (*var_hash)->cur_depth--;
680 …alize(rval, ce, (const unsigned char*)*p, datalen, (zend_unserialize_data *)var_hash) != SUCCESS) {
716 tmp = tmp_var(var_hash, 2);
745 zval *wakeup_var = var_tmp_var(var_hash);
758 var_entries *orig_var_entries = (*var_hash)->last;
765 /* If the unserialization failed, mark all elements that have been added to var_hash
795 if (var_hash && (*p)[0] != 'R') {
796 var_push(var_hash, rval);
807 if (!var_hash) return 0;
810 if (id == -1 || (rval_ref = var_access(var_hash, id)) == NULL) {
820 if ((*var_hash)->ref_props) {
821 info = zend_hash_index_find_ptr((*var_hash)->ref_props, (zend_uintptr_t) rval_ref);
838 if (!var_hash) return 0;
841 if (id == -1 || (rval_ref = var_access(var_hash, id)) == NULL) {
1002 if (!var_hash) return 0;
1011 reference to some zvals might be kept in var_hash (to support references) */
1045 if (!var_hash) return 0;
1077 if(!unserialize_allowed_class(class_name, var_hash)) {