Merge remote-tracking branch 'upstream/master'

This commit is contained in:
Árpád Bűrmen 2025-09-24 08:29:06 +02:00
commit 8c2c9c34e5
2 changed files with 10 additions and 6 deletions

View File

@ -3083,6 +3083,11 @@ int Tcl_AppInit(Tcl_Interp *inter)
/* */
tcleval("source_user_tcl_files");
/* */
/* Execute tcl commands given in tcl variable postinit_commands if existing */
/* */
tcleval("eval_postinit_commands");
if(cli_opt_filename[0]) {
char f[PATH_MAX];
int file_loaded = 1;
@ -3234,9 +3239,6 @@ int Tcl_AppInit(Tcl_Interp *inter)
tcleval(cli_opt_tcl_post_command);
}
/* Execute tcl commands given in tcl variable postinit_commands if existing */
tcleval("eval_postinit_commands");
if(cli_opt_quit) {
char s[40];
my_snprintf(s, S(s), "exit %d", exit_code);

View File

@ -9868,9 +9868,11 @@ proc set_replace_key_binding { {win_path {.drw}}} {
}
proc source_user_tcl_files {} {
global tcl_files
foreach i $tcl_files {
uplevel #0 [list source $i]
set subst_tcl_files [uplevel #0 {subst $tcl_files}]
foreach i $subst_tcl_files {
if {[catch "uplevel #0 {[list source $i]}" retval]} {
puts $retval
}
}
}