FreeBSD Bugzilla – Attachment 9093 Details for
Bug 18760
patch: "no inet" flag for /usr/sbin/lpd
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
file.diff
file.diff (text/plain), 1.86 KB, created by
njh
on 2000-05-22 23:00:00 UTC
(
hide
)
Description:
file.diff
Filename:
MIME Type:
Creator:
njh
Created:
2000-05-22 23:00:00 UTC
Size:
1.86 KB
patch
obsolete
>*** usr.sbin/lpr/lpd/lpd.c.orig Mon May 22 21:06:08 2000 >--- usr.sbin/lpr/lpd/lpd.c Mon May 22 21:44:34 2000 >*************** >*** 125,131 **** > int argc; > char **argv; > { >! int f, funix, finet, options, fromlen, i, errs; > fd_set defreadfds; > struct sockaddr_un un, fromunix; > struct sockaddr_in sin, frominet; >--- 125,131 ---- > int argc; > char **argv; > { >! int f, funix, finet, options, fromlen, i, errs, noinet; > fd_set defreadfds; > struct sockaddr_un un, fromunix; > struct sockaddr_in sin, frominet; >*************** >*** 144,150 **** > errx(EX_NOPERM,"must run as root"); > > errs = 0; >! while ((i = getopt(argc, argv, "dl")) != -1) > switch (i) { > case 'd': > options |= SO_DEBUG; >--- 144,151 ---- > errx(EX_NOPERM,"must run as root"); > > errs = 0; >! noinet = 0; >! while ((i = getopt(argc, argv, "dln")) != -1) > switch (i) { > case 'd': > options |= SO_DEBUG; >*************** >*** 152,157 **** >--- 153,161 ---- > case 'l': > lflag++; > break; >+ case 'n': >+ noinet++; >+ break; > default: > errs++; > } >*************** >*** 279,285 **** > FD_SET(funix, &defreadfds); > listen(funix, 5); > finet = socket(AF_INET, SOCK_STREAM, 0); >! if (finet >= 0) { > if (options & SO_DEBUG) > if (setsockopt(finet, SOL_SOCKET, SO_DEBUG, 0, 0) < 0) { > syslog(LOG_ERR, "setsockopt (SO_DEBUG): %m"); >--- 283,289 ---- > FD_SET(funix, &defreadfds); > listen(funix, 5); > finet = socket(AF_INET, SOCK_STREAM, 0); >! if ((finet >= 0) && !noinet) { > if (options & SO_DEBUG) > if (setsockopt(finet, SOL_SOCKET, SO_DEBUG, 0, 0) < 0) { > syslog(LOG_ERR, "setsockopt (SO_DEBUG): %m"); >*************** >*** 629,634 **** > static void > usage() > { >! fprintf(stderr, "usage: lpd [-dl] [port#]\n"); > exit(EX_USAGE); > } >--- 633,638 ---- > static void > usage() > { >! fprintf(stderr, "usage: lpd [-dln] [port#]\n"); > exit(EX_USAGE); > }
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 18760
: 9093 |
9094