mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-06 00:41:15 -03:00
Fix major memory leak in highlighting code and a minor leak in the parser
darcs-hash:20060528110630-ac50b-94a83ec6731b39ebcf864b7491ec3c372e28a135.gz
This commit is contained in:
3
output.c
3
output.c
@@ -544,6 +544,9 @@ int output_color_code( const wchar_t *val )
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
al_foreach( &el, (void (*)(const void *))&free );
|
||||||
|
al_destroy( &el );
|
||||||
|
|
||||||
return color | (is_bold?FISH_COLOR_BOLD:0);
|
return color | (is_bold?FISH_COLOR_BOLD:0);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
2
parser.c
2
parser.c
@@ -1976,7 +1976,7 @@ static int parse_job( process_t *p,
|
|||||||
|
|
||||||
tmp = (wchar_t *)al_get( args, 0 );
|
tmp = (wchar_t *)al_get( args, 0 );
|
||||||
al_truncate( args, 0 );
|
al_truncate( args, 0 );
|
||||||
al_push( args, wcsdup( L"cd" ) );
|
al_push( args, halloc_wcsdup( j, L"cd" ) );
|
||||||
al_push( args, tmp );
|
al_push( args, tmp );
|
||||||
/*
|
/*
|
||||||
If we have defined a wrapper around cd, use it,
|
If we have defined a wrapper around cd, use it,
|
||||||
|
|||||||
Reference in New Issue
Block a user