summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/spawn.cc
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2000-11-08 20:36:37 +0000
committerChristopher Faylor <me@cgf.cx>2000-11-08 20:36:37 +0000
commit9bc846bd3d5fc13eb28b4ddece0ecfc52caf898a (patch)
tree2fd164536ce8697b5dc316629c913edf27dbdbeb /winsup/cygwin/spawn.cc
parent315f8fd37b75a6cfe589afb9eb18cc9bb59874ac (diff)
downloadcygnal-9bc846bd3d5fc13eb28b4ddece0ecfc52caf898a.tar.gz
cygnal-9bc846bd3d5fc13eb28b4ddece0ecfc52caf898a.tar.bz2
cygnal-9bc846bd3d5fc13eb28b4ddece0ecfc52caf898a.zip
* environ.cc (_addenv): malloc space for setenv if cygwin1.dll is used in
conjunction with older binaries. (environ_init): Ditto. * external.cc (get_cygdrive_info): New function. * external.cc (get_cygdrive_prefixes): Change to use get_cygdrive_info but toss the user and system flags. * external.cc (cygwin_internal): Add new CW_GET_CYGDRIVE_INFO case. * path.cc (mount_info::get_cygdrive_prefixes): Remove method. * path.cc (mount_info::get_cygdrive_info): New method. Actually, get_cygdrive_info is really an enhanced version of get_cygdrive_prefixes renamed to get_cygdrive_info that also gets the user and system flags. * shared_info.h (get_cygdrive_prefixes): Remove method. * shared_info.h (get_cygdrive_info): New method. * include/cygwin/version.h: Bump minor API version due to adding CW_GET_CYGDRIVE_INFO to cygwin_internal. * include/sys/cygwin.h (cygwin_getinfo_types): Add CW_GET_CYGDRIVE_INFO.
Diffstat (limited to 'winsup/cygwin/spawn.cc')
-rw-r--r--winsup/cygwin/spawn.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/winsup/cygwin/spawn.cc b/winsup/cygwin/spawn.cc
index 8e2e490be..e17541446 100644
--- a/winsup/cygwin/spawn.cc
+++ b/winsup/cygwin/spawn.cc
@@ -511,7 +511,7 @@ spawn_guts (HANDLE hToken, const char * prog_arg, const char *const *argv,
cygcwd.copy (ciresrv.moreinfo->cwd_posix, ciresrv.moreinfo->cwd_win32,
ciresrv.moreinfo->cwd_hash);
- ciresrv.moreinfo->envc = envsize (envp, 0);
+ ciresrv.moreinfo->envc = envsize (envp, 1);
ciresrv.moreinfo->envp = (char **) cmalloc (HEAP_1_ARGV, ciresrv.moreinfo->envc);
ciresrv.hexec_proc = hexec_proc;
char **c;