pike.git/
src/
mapping.c
Branch:
Tag:
Non-build tags
All tags
No tags
2015-05-31
2015-05-31 16:37:30 by Henrik Grubbström (Grubba) <grubba@grubba.org>
99ac3c5c26dcdb41d88ece80feb3e8570baed0b1 (
11
lines) (+
7
/-
4
)
[
Show
|
Annotate
]
Branch:
8.1
Mapping: Added some consistency checks. Fixes [CID 1294567].
2698:
gc_free_svalue(&k->val); \ else if ((REMOVE = W_REC(&k->val, 1))) \ gc_free_svalue(&k->ind); \
-
else
\
-
N_REC(&k->ind,
1);
/*
Now
we
can
recurse
the
index.
*/
\
+
else
if
(N_REC(&k->ind,
1))
/*
Now
we
can
recurse
the
index.
*/
\
+
Pike_fatal("Mapping:
%s
and
%s
don't
agree.\n",
\
+
TOSTR(N_TST),
TOSTR(N_REC));
\
} while (0) #define GC_REC_KP_BOTH(REMOVE, N_REC, W_REC, N_TST, W_TST) do { \
2707:
gc_free_svalue(&k->val); \ else if ((REMOVE = W_REC(&k->val, 1))) \ gc_free_svalue(&k->ind); \
-
else
\
-
W_REC(&k->ind,
1);
/*
Now
we
can
recurse
the
index.
*/
\
+
else
if
(W_REC(&k->ind,
1))
/*
Now
we
can
recurse
the
index.
*/
\
+
Pike_fatal("Mapping:
%s
and
%s
don't
agree.\n",
\
+
TOSTR(W_TST),
TOSTR(W_REC));
\
} while (0) void gc_mark_mapping_as_referenced(struct mapping *m)