Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'winsup/cygwin/cygrun.c')
-rw-r--r--winsup/cygwin/cygrun.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/winsup/cygwin/cygrun.c b/winsup/cygwin/cygrun.c
index 94b0c399f..63d9863f7 100644
--- a/winsup/cygwin/cygrun.c
+++ b/winsup/cygwin/cygrun.c
@@ -36,10 +36,13 @@ main (int argc, char **argv)
{
char buf[4096];
if (!p)
- p[0] = '\0';
+ {
+ p = buf;
+ p[0] = '\0';
+ }
else
{
- strcat (buf, p);
+ strcpy (buf, p);
strcat (buf, " ");
}
strcat(buf, "ntsec");