diff --git a/complete.c b/complete.c index 48ec50ceb..f1e409909 100644 --- a/complete.c +++ b/complete.c @@ -1081,7 +1081,7 @@ static void copy_strings_with_prefix( array_list_t *comp_out, wchar_t *wc, *tmp; tmp = expand_one( 0, - wcsdup(wc_escaped), EXPAND_SKIP_SUBSHELL | EXPAND_SKIP_WILDCARDS); + wcsdup(wc_escaped), EXPAND_SKIP_CMDSUBST | EXPAND_SKIP_WILDCARDS); if(!tmp) return; @@ -1786,14 +1786,14 @@ static void complete_param_expand( wchar_t *str, } /* debug( 3, - L"expand_string( \"%ls\", comp_out, EXPAND_SKIP_SUBSHELL | ACCEPT_INCOMPLETE | %ls );", + L"expand_string( \"%ls\", comp_out, EXPAND_SKIP_CMDSUBST | ACCEPT_INCOMPLETE | %ls );", comp_str, do_file?L"0":L"EXPAND_SKIP_WILDCARDS" ); */ expand_string( 0, wcsdup(comp_str), comp_out, - EXPAND_SKIP_SUBSHELL | ACCEPT_INCOMPLETE | (do_file?0:EXPAND_SKIP_WILDCARDS) ); + EXPAND_SKIP_CMDSUBST | ACCEPT_INCOMPLETE | (do_file?0:EXPAND_SKIP_WILDCARDS) ); } /** diff --git a/expand.c b/expand.c index 21bfe0e23..785a7c9b4 100644 --- a/expand.c +++ b/expand.c @@ -1184,9 +1184,9 @@ static int expand_brackets( wchar_t *in, int flags, array_list_t *out ) } /** - Perform subshell expansion + Perform cmdsubst expansion */ -static int expand_subshell( wchar_t *in, array_list_t *out ) +static int expand_cmdsubst( wchar_t *in, array_list_t *out ) { wchar_t *paran_begin=0, *paran_end=0; int len1, len2; @@ -1241,7 +1241,7 @@ static int expand_subshell( wchar_t *in, array_list_t *out ) } al_init( &tail_expand ); - expand_subshell( wcsdup(paran_end+1), &tail_expand ); + expand_cmdsubst( wcsdup(paran_end+1), &tail_expand ); for( i=0; i