projects
/
unix-history
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
tags
|
clone url
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
sockaddr's now require length (K. Sklower);
[unix-history]
/
usr
/
src
/
lib
/
libc
/
net
/
herror.c
diff --git
a/usr/src/lib/libc/net/herror.c
b/usr/src/lib/libc/net/herror.c
index
1030f49
..
615ac62
100644
(file)
--- a/
usr/src/lib/libc/net/herror.c
+++ b/
usr/src/lib/libc/net/herror.c
@@
-16,7
+16,7
@@
*/
#if defined(LIBC_SCCS) && !defined(lint)
*/
#if defined(LIBC_SCCS) && !defined(lint)
-static char sccsid[] = "@(#)herror.c 6.
3
(Berkeley) %G%";
+static char sccsid[] = "@(#)herror.c 6.
4
(Berkeley) %G%";
#endif /* LIBC_SCCS and not lint */
#include <sys/types.h>
#endif /* LIBC_SCCS and not lint */
#include <sys/types.h>
@@
-51,7
+51,8
@@
herror(s)
v->iov_len = 2;
v++;
}
v->iov_len = 2;
v++;
}
- v->iov_base = h_errno < h_nerr ? h_errlist[h_errno] : "Unknown error";
+ v->iov_base = (u_int)h_errno < h_nerr ?
+ h_errlist[h_errno] : "Unknown error";
v->iov_len = strlen(v->iov_base);
v++;
v->iov_base = "\n";
v->iov_len = strlen(v->iov_base);
v++;
v->iov_base = "\n";