mirror of
https://github.com/fish-shell/fish-shell.git
synced 2025-01-18 09:32:47 +08:00
Do not try to read init files if the cd to the proper directory fails
darcs-hash:20060511115758-ac50b-94661cb36c5a55bc78ddfe576d1cd40fada5f065.gz
This commit is contained in:
parent
af8e053896
commit
94abb30f94
8
main.c
8
main.c
|
@ -80,9 +80,9 @@ static int read_init()
|
|||
|
||||
env_set( L"__fish_help_dir", DOCDIR, 0);
|
||||
|
||||
eval( L"builtin cd " DATADIR L"/fish 2>/dev/null; . fish 2>/dev/null", 0, TOP );
|
||||
eval( L"builtin cd " SYSCONFDIR L" 2>/dev/null; . fish 2>/dev/null", 0, TOP );
|
||||
eval( L"builtin cd 2>/dev/null;. .fish 2>/dev/null", 0, TOP );
|
||||
eval( L"builtin cd " DATADIR L"/fish 2>/dev/null; and . fish 2>/dev/null", 0, TOP );
|
||||
eval( L"builtin cd " SYSCONFDIR L" 2>/dev/null; and . fish 2>/dev/null", 0, TOP );
|
||||
eval( L"builtin cd 2>/dev/null; and . .fish 2>/dev/null", 0, TOP );
|
||||
|
||||
if( chdir( cwd ) == -1 )
|
||||
{
|
||||
|
@ -336,7 +336,7 @@ int main( int argc, char **argv )
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
proc_fire_event( L"PROCESS_EXIT", EVENT_EXIT, getpid(), res );
|
||||
|
||||
history_destroy();
|
||||
|
|
Loading…
Reference in New Issue
Block a user