# HG changeset patch # User Rob Landley # Date 1204861285 21600 # Node ID 9efc5fedd108c944ed91cff3a711d15a9182997f # Parent d1fe34c5b92e427037eacd69b6cd9e5023f5605d Make c67 compile again. (If anybody knows what C67 _is_, I'm a bit curious...) diff -r d1fe34c5b92e -r 9efc5fedd108 c67-gen.c --- a/c67-gen.c Thu Mar 06 21:20:30 2008 -0600 +++ b/c67-gen.c Thu Mar 06 21:41:25 2008 -0600 @@ -1952,7 +1952,7 @@ /* define parameters */ while ((sym = sym->next) != NULL) { type = &sym->type; - sym_push(sym->v & ~SYM_FIELD, type, VT_LOCAL | VT_LVAL, addr); + sym_push(sym->token & ~SYM_FIELD, type, VT_LOCAL | VT_LVAL, addr); size = type_size(type, &align); size = (size + 3) & ~3; diff -r d1fe34c5b92e -r 9efc5fedd108 tcccoff.c --- a/tcccoff.c Thu Mar 06 21:20:30 2008 -0600 +++ b/tcccoff.c Thu Mar 06 21:41:25 2008 -0600 @@ -499,7 +499,7 @@ int nstr; int n = 0; - Coff_str_table = (char *) tcc_malloc(MAX_STR_TABLE); + Coff_str_table = (char *) xmalloc(MAX_STR_TABLE); pCoff_str_table = Coff_str_table; nstr = 0; @@ -685,7 +685,7 @@ Elf32_Sym *p, *p2, *NewTable; char *name, *name2; - NewTable = (Elf32_Sym *) tcc_malloc(nb_syms * sizeof(Elf32_Sym)); + NewTable = (Elf32_Sym *) xmalloc(nb_syms * sizeof(Elf32_Sym)); p = (Elf32_Sym *) symtab_section->data; @@ -885,7 +885,7 @@ error("error reading .out file for input"); - Coff_str_table = (char *) tcc_malloc(str_size); + Coff_str_table = (char *) xmalloc(str_size); if (fread(Coff_str_table, str_size - 4, 1, f) != 1) error("error reading .out file for input");