Some VM fixes

db4
Slava Pestov 2009-05-04 15:11:31 -05:00
parent 21aeda1324
commit 0682c3da39
2 changed files with 3 additions and 4 deletions

View File

@ -218,10 +218,7 @@ void update_word_references(code_block *compiled)
the code heap with dead PICs that will be freed on the next
GC, we add them to the free list immediately. */
else if(compiled->block.type == PIC_TYPE)
{
fflush(stdout);
heap_free(&code,&compiled->block);
}
else
{
iterate_relocations(compiled,update_word_references_step);

View File

@ -108,7 +108,9 @@ PRIMITIVE(string)
static bool reallot_string_in_place_p(string *str, cell capacity)
{
return in_zone(&nursery,str) && capacity <= string_capacity(str);
return in_zone(&nursery,str)
&& (str->aux == F || in_zone(&nursery,untag<byte_array>(str->aux)))
&& capacity <= string_capacity(str);
}
string* reallot_string(string *str_, cell capacity)