mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-03 21:18:59 +00:00
shutdown(2)'s how argument as 0 is nowhere near as cool as SHUT_RD
This commit is contained in:
parent
e8b92d55b6
commit
b894acfb2a
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=146079
@ -208,7 +208,7 @@ flushroutes(argc, argv)
|
||||
if (uid && !debugonly) {
|
||||
errx(EX_NOPERM, "must be root to alter routing table");
|
||||
}
|
||||
shutdown(s, 0); /* Don't want to read back our messages */
|
||||
shutdown(s, SHUT_RD); /* Don't want to read back our messages */
|
||||
if (argc > 1) {
|
||||
argv++;
|
||||
if (argc == 2 && **argv == '-')
|
||||
@ -577,7 +577,7 @@ newroute(argc, argv)
|
||||
}
|
||||
cmd = argv[0];
|
||||
if (*cmd != 'g')
|
||||
shutdown(s, 0); /* Don't want to read back our messages */
|
||||
shutdown(s, SHUT_RD); /* Don't want to read back our messages */
|
||||
while (--argc > 0) {
|
||||
if (**(++argv)== '-') {
|
||||
switch (key = keyword(1 + *argv)) {
|
||||
|
Loading…
Reference in New Issue
Block a user