summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog9
-rw-r--r--openbsd-compat/inet_ntop.c8
-rw-r--r--openbsd-compat/openbsd-compat.h4
3 files changed, 12 insertions, 9 deletions
diff --git a/ChangeLog b/ChangeLog
index 2606178a0..5c9d719ba 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -15,17 +15,20 @@
15 Convert do {} while loop -> while {} for clarity. No binary change 15 Convert do {} while loop -> while {} for clarity. No binary change
16 on most architectures. From Oliver Smith. OK deraadt@ and henning@ 16 on most architectures. From Oliver Smith. OK deraadt@ and henning@
17 - tobias@cvs.openbsd.org 2007/10/21 11:09:30 17 - tobias@cvs.openbsd.org 2007/10/21 11:09:30
18 [mktemp.c] 18 [openbsd-compat/mktemp.c]
19 Comment fix about time consumption of _gettemp. 19 Comment fix about time consumption of _gettemp.
20 FreeBSD did this in revision 1.20. 20 FreeBSD did this in revision 1.20.
21 OK deraadt@, krw@ 21 OK deraadt@, krw@
22 - deraadt@cvs.openbsd.org 2008/07/22 21:47:45 22 - deraadt@cvs.openbsd.org 2008/07/22 21:47:45
23 [mktemp.c] 23 [openbsd-compat/mktemp.c]
24 use arc4random_uniform(); ok djm millert 24 use arc4random_uniform(); ok djm millert
25 - millert@cvs.openbsd.org 2008/08/21 16:54:44 25 - millert@cvs.openbsd.org 2008/08/21 16:54:44
26 [mktemp.c] 26 [openbsd-compat/mktemp.c]
27 Remove useless code, the kernel will set errno appropriately if an 27 Remove useless code, the kernel will set errno appropriately if an
28 element in the path does not exist. OK deraadt@ pvalchev@ 28 element in the path does not exist. OK deraadt@ pvalchev@
29 - otto@cvs.openbsd.org 2008/12/09 19:38:38
30 [openbsd-compat/inet_ntop.c]
31 fix inet_ntop(3) prototype; ok millert@ libc to be bumbed very soon
29 32
3020110922 3320110922
31 - OpenBSD CVS Sync 34 - OpenBSD CVS Sync
diff --git a/openbsd-compat/inet_ntop.c b/openbsd-compat/inet_ntop.c
index e7ca4b7f8..3259037ba 100644
--- a/openbsd-compat/inet_ntop.c
+++ b/openbsd-compat/inet_ntop.c
@@ -1,4 +1,4 @@
1/* $OpenBSD: inet_ntop.c,v 1.7 2005/08/06 20:30:03 espie Exp $ */ 1/* $OpenBSD: inet_ntop.c,v 1.8 2008/12/09 19:38:38 otto Exp $ */
2 2
3/* Copyright (c) 1996 by Internet Software Consortium. 3/* Copyright (c) 1996 by Internet Software Consortium.
4 * 4 *
@@ -57,13 +57,13 @@ static const char *inet_ntop6(const u_char *src, char *dst, size_t size);
57 * Paul Vixie, 1996. 57 * Paul Vixie, 1996.
58 */ 58 */
59const char * 59const char *
60inet_ntop(int af, const void *src, char *dst, size_t size) 60inet_ntop(int af, const void *src, char *dst, socklen_t size)
61{ 61{
62 switch (af) { 62 switch (af) {
63 case AF_INET: 63 case AF_INET:
64 return (inet_ntop4(src, dst, size)); 64 return (inet_ntop4(src, dst, (size_t)size));
65 case AF_INET6: 65 case AF_INET6:
66 return (inet_ntop6(src, dst, size)); 66 return (inet_ntop6(src, dst, (size_t)size));
67 default: 67 default:
68 errno = EAFNOSUPPORT; 68 errno = EAFNOSUPPORT;
69 return (NULL); 69 return (NULL);
diff --git a/openbsd-compat/openbsd-compat.h b/openbsd-compat/openbsd-compat.h
index 77c5ed2b1..807acf626 100644
--- a/openbsd-compat/openbsd-compat.h
+++ b/openbsd-compat/openbsd-compat.h
@@ -1,4 +1,4 @@
1/* $Id: openbsd-compat.h,v 1.51 2010/10/07 10:25:29 djm Exp $ */ 1/* $Id: openbsd-compat.h,v 1.52 2011/09/23 01:16:11 djm Exp $ */
2 2
3/* 3/*
4 * Copyright (c) 1999-2003 Damien Miller. All rights reserved. 4 * Copyright (c) 1999-2003 Damien Miller. All rights reserved.
@@ -116,7 +116,7 @@ char *inet_ntoa(struct in_addr in);
116#endif 116#endif
117 117
118#ifndef HAVE_INET_NTOP 118#ifndef HAVE_INET_NTOP
119const char *inet_ntop(int af, const void *src, char *dst, size_t size); 119const char *inet_ntop(int af, const void *src, char *dst, socklen_t size);
120#endif 120#endif
121 121
122#ifndef HAVE_INET_ATON 122#ifndef HAVE_INET_ATON