patch 9.0.0217: 'shellslash' works differently when sourcing a script again

Problem:    'shellslash' works differently when sourcing a script again.
Solution:   Use the name from the script item. (closes #10920)
This commit is contained in:
zeertzjq
2022-08-15 17:53:55 +01:00
committed by Bram Moolenaar
parent cce293f87b
commit 5a4fff4d94
3 changed files with 32 additions and 5 deletions

View File

@ -1534,10 +1534,6 @@ do_source_ext(
cookie.level = ex_nesting_level;
#endif
// Keep the sourcing name/lnum, for recursive calls.
estack_push(ETYPE_SCRIPT, fname_exp, 0);
ESTACK_CHECK_SETUP
#ifdef STARTUPTIME
if (time_fd != NULL)
time_push(&tv_rel, &tv_start);
@ -1630,6 +1626,10 @@ do_source_ext(
si->sn_is_vimrc = is_vimrc;
}
// Keep the sourcing name/lnum, for recursive calls.
estack_push(ETYPE_SCRIPT, si->sn_name, 0);
ESTACK_CHECK_SETUP
# ifdef FEAT_PROFILE
if (do_profiling == PROF_YES)
{