Allow newlines in fish_prompt, by joining prompt_list with newlines instead of nothing in exec_prompt().

This commit is contained in:
Ben Hoskings 2009-11-25 01:12:44 +11:00 committed by Suraj N. Kurapati
parent 6b8e7b16f6
commit 1157e4d7b2

View file

@ -698,6 +698,10 @@ static void exec_prompt()
for( i=0; i<al_get_count( &prompt_list); i++ ) for( i=0; i<al_get_count( &prompt_list); i++ )
{ {
sb_append( &data->prompt_buff, (wchar_t *)al_get( &prompt_list, i ) ); sb_append( &data->prompt_buff, (wchar_t *)al_get( &prompt_list, i ) );
if (i + 1 < al_get_count( &prompt_list))
{
sb_append( &data->prompt_buff, L"\n" );
}
} }
al_foreach( &prompt_list, &free ); al_foreach( &prompt_list, &free );