aboutsummaryrefslogtreecommitdiff
path: root/gcc/objc
diff options
context:
space:
mode:
authorKresten Krab Thorup <krab@gcc.gnu.org>1994-10-06 16:17:38 +0000
committerKresten Krab Thorup <krab@gcc.gnu.org>1994-10-06 16:17:38 +0000
commitb962cd0b239656dac5c053e29460de730b8848c5 (patch)
treee3f4910dde31d4e1bb4f0e32a38a1ffe2b75121c /gcc/objc
parent9a9a996b7b83ac05a2ff8715051a86a3abf59f39 (diff)
downloadgcc-b962cd0b239656dac5c053e29460de730b8848c5.zip
gcc-b962cd0b239656dac5c053e29460de730b8848c5.tar.gz
gcc-b962cd0b239656dac5c053e29460de730b8848c5.tar.bz2
Delay eeing when unarchiving.
From-SVN: r8229
Diffstat (limited to 'gcc/objc')
-rw-r--r--gcc/objc/archive.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/gcc/objc/archive.c b/gcc/objc/archive.c
index 71cac4f..f78f787 100644
--- a/gcc/objc/archive.c
+++ b/gcc/objc/archive.c
@@ -1427,9 +1427,11 @@ static void __objc_finish_write_root_object(struct objc_typed_stream* stream)
static void __objc_finish_read_root_object(struct objc_typed_stream* stream)
{
node_ptr node;
+ struct objc_list* free_list;
SEL awake_sel = sel_get_any_uid ("awake");
/* resolve object forward references */
+ free_list = list_cons(NULL, NULL);
for (node = hash_next (stream->object_refs, NULL); node;
node = hash_next (stream->object_refs, node))
{
@@ -1439,10 +1441,13 @@ static void __objc_finish_read_root_object(struct objc_typed_stream* stream)
while(reflist)
{
*((id*)reflist->head) = object;
+ if (list_find(&free_list, reflist) == NULL)
+ free_list = list_cons (reflist, free_list);
reflist = reflist->tail;
}
- list_free (node->value);
}
+ list_mapcar (free_list, free);
+ list_free (free_list);
/* empty object reference table */
hash_delete (stream->object_refs);