mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-06-05 08:11:15 -03:00
Minor edits
darcs-hash:20051211233939-ac50b-e01a4024f70355f2b7f1b5377c6e0853997d9860.gz
This commit is contained in:
11
parser.c
11
parser.c
@@ -598,6 +598,8 @@ wchar_t *get_filename( const wchar_t *cmd )
|
||||
{
|
||||
wchar_t *path;
|
||||
|
||||
debug( 2, L"get_filename( '%ls' )", cmd );
|
||||
|
||||
if(wcschr( cmd, '/' ) != 0 )
|
||||
{
|
||||
if( waccess( cmd, X_OK )==0 )
|
||||
@@ -1316,7 +1318,7 @@ static int parse_job( process_t *p,
|
||||
|
||||
block_t *prev_block = current_block;
|
||||
|
||||
// debug( 2, L"begin parse_job()\n" );
|
||||
debug( 2, L"begin parse_job()\n" );
|
||||
al_init( &args );
|
||||
|
||||
current_tokenizer_pos = tok_get_pos( tok );
|
||||
@@ -1330,6 +1332,8 @@ static int parse_job( process_t *p,
|
||||
{
|
||||
nxt = expand_one( wcsdup(tok_last( tok )),
|
||||
EXPAND_SKIP_SUBSHELL | EXPAND_SKIP_VARIABLES);
|
||||
debug( 2, L"command '%ls' -> '%ls'", tok_last( tok ), nxt?nxt:L"0" );
|
||||
|
||||
if( nxt == 0 )
|
||||
{
|
||||
error( SYNTAX_ERROR,
|
||||
@@ -1567,6 +1571,9 @@ static int parse_job( process_t *p,
|
||||
{
|
||||
|
||||
p->actual_cmd = get_filename( (wchar_t *)al_get( &args, 0 ) );
|
||||
|
||||
debug( 2, L"filename '%ls' -> '%ls'", (wchar_t *)al_get( &args, 0 ), p->actual_cmd?p->actual_cmd:L"0" );
|
||||
|
||||
/*
|
||||
Check if the specified command exists
|
||||
*/
|
||||
@@ -1972,8 +1979,6 @@ int eval( const wchar_t *cmd, io_data_t *io, int block_type )
|
||||
io_data_t *prev_io = block_io;
|
||||
block_io = io;
|
||||
|
||||
debug( 2, L"Eval command %ls", cmd );
|
||||
|
||||
job_reap( 0 );
|
||||
|
||||
if( !cmd )
|
||||
|
||||
Reference in New Issue
Block a user