summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/spawn.cc
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/cygwin/spawn.cc')
-rw-r--r--winsup/cygwin/spawn.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/winsup/cygwin/spawn.cc b/winsup/cygwin/spawn.cc
index b1cd0796a..352d408d1 100644
--- a/winsup/cygwin/spawn.cc
+++ b/winsup/cygwin/spawn.cc
@@ -546,7 +546,8 @@ spawn_guts (const char * prog_arg, const char *const *argv,
{
debug_printf ("Command line too long (>32K), return E2BIG");
set_errno (E2BIG);
- return -1;
+ res = -1;
+ goto out;
}
}
@@ -714,7 +715,8 @@ spawn_guts (const char * prog_arg, const char *const *argv,
myself->sendsig = myself->exec_sendsig;
myself->exec_sendsig = NULL;
}
- return -1;
+ res = -1;
+ goto out;
}
/* Fixup the parent data structures if needed and resume the child's