diff options
author | Christopher Faylor <me@cgf.cx> | 2006-07-05 00:14:42 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2006-07-05 00:14:42 +0000 |
commit | 49bd27c47c3e4d6b56b4758bd8e17d7f46c20818 (patch) | |
tree | 0f800672aa9ddf0280a924291d95f5471ccb7841 /winsup | |
parent | 0a22f2e537ff2e44070c94b239658f12df3fd5b9 (diff) | |
download | cygnal-49bd27c47c3e4d6b56b4758bd8e17d7f46c20818.tar.gz cygnal-49bd27c47c3e4d6b56b4758bd8e17d7f46c20818.tar.bz2 cygnal-49bd27c47c3e4d6b56b4758bd8e17d7f46c20818.zip |
* libc/rexec.cc (cygwin_rexec): Obvious (?) fix to correct a gcc warning - set
port to zero first thing in the function.
Diffstat (limited to 'winsup')
-rw-r--r-- | winsup/cygwin/ChangeLog | 5 | ||||
-rw-r--r-- | winsup/cygwin/libc/rexec.cc | 3 |
2 files changed, 6 insertions, 2 deletions
diff --git a/winsup/cygwin/ChangeLog b/winsup/cygwin/ChangeLog index 5b60fe365..40a7c43c3 100644 --- a/winsup/cygwin/ChangeLog +++ b/winsup/cygwin/ChangeLog @@ -1,3 +1,8 @@ +2006-07-04 Christopher Faylor <cgf@timesys.com> + + * libc/rexec.cc (cygwin_rexec): Obvious (?) fix to correct a gcc + warning - set port to zero first thing in the function. + 2006-07-04 Corinna Vinschen <corinna@vinschen.de> * signal.cc (signal): Set sa_mask to sig. diff --git a/winsup/cygwin/libc/rexec.cc b/winsup/cygwin/libc/rexec.cc index 2d4726b16..99d76f68c 100644 --- a/winsup/cygwin/libc/rexec.cc +++ b/winsup/cygwin/libc/rexec.cc @@ -317,7 +317,7 @@ cygwin_rexec (char **ahost, unsigned short rport, char *name, char *pass, { struct sockaddr_in sin, sin2, from; struct hostent *hp; - u_short port; + u_short port = 0; int s, timo = 1, s3; char c; char ahostbuf[INTERNET_MAX_HOST_NAME_LENGTH + 1]; @@ -359,7 +359,6 @@ retry: } if (fd2p == 0) { (void) write(s, "", 1); - port = 0; } else { char num[8]; int s2, sin2len; |