From: Stefan Monnier Date: Fri, 31 Aug 2007 05:22:22 +0000 (+0000) Subject: (set_initial_environment): Set Vinitial_environment only when X-Git-Tag: emacs-pretest-23.0.90~11181 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=3c33c79aaf91eb7ddd6abb247a99ee188495615f;p=emacs.git (set_initial_environment): Set Vinitial_environment only when Vprocess_environment is built, otherwise I get an unexplained infinite loop. (child_setup): Remove unused vars term_var and display_var. --- diff --git a/src/callproc.c b/src/callproc.c index 66d11ff402c..d99dd8b90bb 100644 --- a/src/callproc.c +++ b/src/callproc.c @@ -1245,8 +1245,6 @@ child_setup (in, out, err, new_argv, set_pgrp, current_dir) { char **env; char *pwd_var; - char *term_var; - char *display_var; #ifdef WINDOWSNT int cpid; HANDLE handles[3]; @@ -1818,7 +1816,6 @@ void set_initial_environment () { register char **envp; - Lisp_Object env = Vprocess_environment; #ifndef CANNOT_DUMP if (initialized) #endif @@ -1827,10 +1824,10 @@ set_initial_environment () Vprocess_environment = Fcons (build_string (*envp), Vprocess_environment); store_frame_param (SELECTED_FRAME(), Qenvironment, Vprocess_environment); + /* Ideally, the `copy' shouldn't be necessary, but it seems it's frequent + to use `delete' and friends on process-environment. */ + Vinitial_environment = Fcopy_sequence (Vprocess_environment); } - /* Ideally, the `copy' shouldn't be necessary, but it seems it's frequent - to use `delete' and friends on process-environment. */ - Vinitial_environment = Fcopy_sequence (Vprocess_environment); } void