aboutsummaryrefslogtreecommitdiff
path: root/winsup
diff options
context:
space:
mode:
authorChristopher Faylor <me@cgf.cx>2002-03-22 03:24:30 +0000
committerChristopher Faylor <me@cgf.cx>2002-03-22 03:24:30 +0000
commit45d2ea8a52d1cd9d50ca7029a70da413e522932e (patch)
tree0e95bca04c9eea1bdb26cf55d4416178b46855fd /winsup
parente7ac2b2299f7aa6c43e4d6c47ae11b42c37b5f2e (diff)
downloadnewlib-45d2ea8a52d1cd9d50ca7029a70da413e522932e.zip
newlib-45d2ea8a52d1cd9d50ca7029a70da413e522932e.tar.gz
newlib-45d2ea8a52d1cd9d50ca7029a70da413e522932e.tar.bz2
* spawn.cc (find_exec): Return input if file not found.
Diffstat (limited to 'winsup')
-rw-r--r--winsup/cygwin/ChangeLog4
-rw-r--r--winsup/cygwin/spawn.cc4
2 files changed, 7 insertions, 1 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog
index 00b5092..a013038 100644
--- a/winsup/cygwin/ChangeLog
+++ b/winsup/cygwin/ChangeLog
@@ -1,3 +1,7 @@
+2002-03-21 Christopher Faylor <cgf@redhat.com>
+
+ * spawn.cc (find_exec): Return input if file not found.
+
2002-03-19 Boris Schaeling <boriss@web.de>
* poll.cc (poll): Add support for invalid descriptors.
diff --git a/winsup/cygwin/spawn.cc b/winsup/cygwin/spawn.cc
index b5dc670..9020665 100644
--- a/winsup/cygwin/spawn.cc
+++ b/winsup/cygwin/spawn.cc
@@ -89,7 +89,7 @@ find_exec (const char *name, path_conv& buf, const char *mywinenv,
{
const char *suffix = "";
debug_printf ("find_exec (%s)", name);
- char *retval = buf;
+ const char *retval = buf;
char tmp[MAX_PATH];
const char *posix = (opt & FE_NATIVE) ? NULL : name;
bool has_slash = strchr (name, '/');
@@ -166,6 +166,8 @@ find_exec (const char *name, path_conv& buf, const char *mywinenv,
retval = NULL;
else if (opt & FE_NATIVE)
buf.check (name);
+ else
+ retval = name;
out:
if (posix)