FreeBSD Bugzilla – Attachment 12892 Details for
Bug 24707
[patch] Whois IP Address Handling
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
file.diff
file.diff (text/plain), 936 bytes, created by
mike
on 2001-01-29 00:30:01 UTC
(
hide
)
Description:
file.diff
Filename:
MIME Type:
Creator:
mike
Created:
2001-01-29 00:30:01 UTC
Size:
936 bytes
patch
obsolete
>--- whois.c.orig Fri Jul 7 07:52:21 2000 >+++ whois.c Sun Jan 28 19:08:14 2001 >@@ -49,6 +49,7 @@ > #include <sys/socket.h> > #include <netinet/in.h> > #include <arpa/inet.h> >+#include <ctype.h> > #include <err.h> > #include <netdb.h> > #include <stdio.h> >@@ -166,13 +167,19 @@ > } > } > if (j != 0) { >- qnichost = (char *) calloc(i - j + 1 + >- strlen(QNICHOST_TAIL), sizeof(char)); >- if (!qnichost) { >- err(1, "calloc"); >+ if (isdigit(*(*argv + j + 1))) { >+ (void) asprintf(&qnichost, "%s", >+ ANICHOST); >+ } else { >+ qnichost = (char *) calloc(i - j >+ + 1 + strlen(QNICHOST_TAIL), >+ sizeof(char)); >+ if (!qnichost) { >+ err(1, "calloc"); >+ } >+ strcpy(qnichost, *argv + j + 1); >+ strcat(qnichost, QNICHOST_TAIL); > } >- strcpy(qnichost, *argv + j + 1); >- strcat(qnichost, QNICHOST_TAIL); > > memset(&hints, 0, sizeof(hints)); > hints.ai_flags = 0;
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 24707
: 12892 |
12893