Remove two minor memory leaks

darcs-hash:20060514223903-ac50b-4e764c460effd8c45493acfe5682626c3711c77e.gz
This commit is contained in:
axel
2006-05-15 08:39:03 +10:00
parent 5a7a264b96
commit dbb66e1895
3 changed files with 10 additions and 8 deletions

View File

@@ -2107,12 +2107,13 @@ static int parse_job( process_t *p,
{
int end_pos = end-tok_string( tok );
wchar_t *sub_block= wcsndup( tok_string( tok ) + current_tokenizer_pos,
end_pos - current_tokenizer_pos);
wchar_t *sub_block= halloc_wcsndup( j,
tok_string( tok ) + current_tokenizer_pos,
end_pos - current_tokenizer_pos);
p->type = INTERNAL_BLOCK;
al_set( args, 0, sub_block );
tok_set_pos( tok,
end_pos );