]> git.pld-linux.org Git - packages/mksh.git/commitdiff
- /etc/mkshrc should not be read if ENV is set
authorKacper Kornet <draenog@pld-linux.org>
Thu, 7 Jul 2011 17:27:08 +0000 (17:27 +0000)
committercvs2git <feedback@pld-linux.org>
Sun, 24 Jun 2012 12:13:13 +0000 (12:13 +0000)
Changed files:
    mksh-mkshrc_support.patch -> 1.2

mksh-mkshrc_support.patch

index 4208a6529f0979731375af12d23f7aa5b52da30d..89a7620ba7ccab053c72584948d2c9bf23c37987 100644 (file)
@@ -1,13 +1,22 @@
---- main.c~    2011-07-06 20:43:36.679601770 +0100
-+++ main.c     2011-07-06 20:43:28.039694865 +0100
-@@ -532,6 +532,7 @@
-       else if (Flag(FTALKING)) {
+--- main.c~    2011-07-07 18:15:26.961632040 +0100
++++ main.c     2011-07-07 18:15:50.664694256 +0100
+@@ -532,10 +532,14 @@
                char *env_file;
  
-+              include("/etc/mkshrc", 0, NULL, 1);
                /* include $ENV */
-               env_file = substitute(substitute("${ENV:-" MKSHRC_PATH "}", 0),
-                   DOTILDE);
+-              env_file = substitute(substitute("${ENV:-" MKSHRC_PATH "}", 0),
+-                  DOTILDE);
++                env_file = substitute("${ENV}", 0);
+               if (*env_file != '\0')
+                       include(env_file, 0, NULL, 1);
++                else { 
++                      env_file = substitute(MKSHRC_PATH, DOTILDE);
++                      include("/etc/mkshrc", 0, NULL, 1);
++                      include(env_file, 0, NULL, 1);
++                        }
+       }
+       if (restricted) {
 --- check.t~   2011-07-07 09:55:26.802497928 +0100
 +++ check.t    2011-07-07 09:55:31.859107570 +0100
 @@ -5908,13 +5908,13 @@
This page took 0.125593 seconds and 4 git commands to generate.