projects
/
oweals
/
busybox.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6f6aa9b
)
Shutdown sending on the socket when stdin closes.
author
Matt Kraai
<kraai@debian.org>
Thu, 14 Dec 2000 04:34:58 +0000
(
04:34
-0000)
committer
Matt Kraai
<kraai@debian.org>
Thu, 14 Dec 2000 04:34:58 +0000
(
04:34
-0000)
nc.c
patch
|
blob
|
history
networking/nc.c
patch
|
blob
|
history
diff --git
a/nc.c
b/nc.c
index 805bbd4d8050a717c421280dec1fb944a55dcf8b..84c1a815eddcf6aac40d777a0992e6d04c9dda0d 100644
(file)
--- a/
nc.c
+++ b/
nc.c
@@
-111,6
+111,8
@@
int nc_main(int argc, char **argv)
exit(0);
ofd = fileno(stdout);
} else {
+ if (nread == 0)
+ shutdown(sfd, 1);
ofd = sfd;
}
diff --git
a/networking/nc.c
b/networking/nc.c
index 805bbd4d8050a717c421280dec1fb944a55dcf8b..84c1a815eddcf6aac40d777a0992e6d04c9dda0d 100644
(file)
--- a/
networking/nc.c
+++ b/
networking/nc.c
@@
-111,6
+111,8
@@
int nc_main(int argc, char **argv)
exit(0);
ofd = fileno(stdout);
} else {
+ if (nread == 0)
+ shutdown(sfd, 1);
ofd = sfd;
}