creates a default path which is used for running scripts
authorewt <devnull@localhost>
Fri, 1 Mar 1996 01:59:03 +0000 (01:59 +0000)
committerewt <devnull@localhost>
Fri, 1 Mar 1996 01:59:03 +0000 (01:59 +0000)
CVS patchset: 444
CVS date: 1996/03/01 01:59:03

lib/uninstall.c

index bfcd3fe..083ea52 100644 (file)
@@ -15,6 +15,9 @@
 #include "rpmerr.h"
 #include "rpmlib.h"
 
+static char * SCRIPT_PATH = "export PATH=/sbin:/bin:/usr/sbin:/usr/bin:"
+                                        "/usr/X11R6/bin\n";
+
 enum fileActions { REMOVE, BACKUP, KEEP };
 
 static int sharedFileCmp(const void * one, const void * two);
@@ -278,6 +281,7 @@ int runScript(char * prefix, Header h, int tag) {
             error(RPMERR_SCRIPT, "error creating file for (un)install script");
            return 1;
        }
+       write(fd, SCRIPT_PATH, strlen(SCRIPT_PATH));
        write(fd, script, strlen(script));
        
        /* run the script via /bin/sh - just feed the commands to the