diff options
author | guenther <> | 2015-09-13 21:36:08 +0000 |
---|---|---|
committer | guenther <> | 2015-09-13 21:36:08 +0000 |
commit | c221c5094439136f46f34e398f2908ca9b5bfb1d (patch) | |
tree | 0ae1c47910a09246e8fb5bd1eb051e7bce8f1788 | |
parent | a7d607d4cbefc6bbee8e873a463b687f010e2375 (diff) | |
download | openbsd-c221c5094439136f46f34e398f2908ca9b5bfb1d.tar.gz openbsd-c221c5094439136f46f34e398f2908ca9b5bfb1d.tar.bz2 openbsd-c221c5094439136f46f34e398f2908ca9b5bfb1d.zip |
Wrap <arpa/inet.h> and <arpa/nameser.h> so that calls go direct and the
symbols without underbar prefix are all weak
-rw-r--r-- | src/lib/libc/net/inet_addr.c | 3 | ||||
-rw-r--r-- | src/lib/libc/net/inet_network.c | 3 | ||||
-rw-r--r-- | src/lib/libc/net/inet_ntop.c | 3 | ||||
-rw-r--r-- | src/lib/libc/net/inet_pton.c | 3 | ||||
-rw-r--r-- | src/lib/libc/net/res_comp.c | 4 |
5 files changed, 11 insertions, 5 deletions
diff --git a/src/lib/libc/net/inet_addr.c b/src/lib/libc/net/inet_addr.c index 2c9aa3051b..62d46ad664 100644 --- a/src/lib/libc/net/inet_addr.c +++ b/src/lib/libc/net/inet_addr.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: inet_addr.c,v 1.11 2015/01/16 16:48:51 deraadt Exp $ */ | 1 | /* $OpenBSD: inet_addr.c,v 1.12 2015/09/13 21:36:08 guenther Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * ++Copyright++ 1983, 1990, 1993 | 4 | * ++Copyright++ 1983, 1990, 1993 |
@@ -172,3 +172,4 @@ inet_aton(const char *cp, struct in_addr *addr) | |||
172 | addr->s_addr = htonl(val); | 172 | addr->s_addr = htonl(val); |
173 | return (1); | 173 | return (1); |
174 | } | 174 | } |
175 | DEF_WEAK(inet_aton); | ||
diff --git a/src/lib/libc/net/inet_network.c b/src/lib/libc/net/inet_network.c index ecf554e4f9..ef8f21b280 100644 --- a/src/lib/libc/net/inet_network.c +++ b/src/lib/libc/net/inet_network.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: inet_network.c,v 1.11 2013/11/25 17:29:19 deraadt Exp $ */ | 1 | /* $OpenBSD: inet_network.c,v 1.12 2015/09/13 21:36:08 guenther Exp $ */ |
2 | /* | 2 | /* |
3 | * Copyright (c) 1983, 1993 | 3 | * Copyright (c) 1983, 1993 |
4 | * The Regents of the University of California. All rights reserved. | 4 | * The Regents of the University of California. All rights reserved. |
@@ -82,3 +82,4 @@ again: | |||
82 | } | 82 | } |
83 | return (val); | 83 | return (val); |
84 | } | 84 | } |
85 | DEF_WEAK(inet_network); | ||
diff --git a/src/lib/libc/net/inet_ntop.c b/src/lib/libc/net/inet_ntop.c index 722761e2ed..f44dd08022 100644 --- a/src/lib/libc/net/inet_ntop.c +++ b/src/lib/libc/net/inet_ntop.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: inet_ntop.c,v 1.11 2015/01/16 16:48:51 deraadt Exp $ */ | 1 | /* $OpenBSD: inet_ntop.c,v 1.12 2015/09/13 21:36:08 guenther Exp $ */ |
2 | 2 | ||
3 | /* Copyright (c) 1996 by Internet Software Consortium. | 3 | /* Copyright (c) 1996 by Internet Software Consortium. |
4 | * | 4 | * |
@@ -55,6 +55,7 @@ inet_ntop(int af, const void *src, char *dst, socklen_t size) | |||
55 | } | 55 | } |
56 | /* NOTREACHED */ | 56 | /* NOTREACHED */ |
57 | } | 57 | } |
58 | DEF_WEAK(inet_ntop); | ||
58 | 59 | ||
59 | /* const char * | 60 | /* const char * |
60 | * inet_ntop4(src, dst, size) | 61 | * inet_ntop4(src, dst, size) |
diff --git a/src/lib/libc/net/inet_pton.c b/src/lib/libc/net/inet_pton.c index f8e299b7b8..5d7148e8e9 100644 --- a/src/lib/libc/net/inet_pton.c +++ b/src/lib/libc/net/inet_pton.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: inet_pton.c,v 1.9 2015/01/16 16:48:51 deraadt Exp $ */ | 1 | /* $OpenBSD: inet_pton.c,v 1.10 2015/09/13 21:36:08 guenther Exp $ */ |
2 | 2 | ||
3 | /* Copyright (c) 1996 by Internet Software Consortium. | 3 | /* Copyright (c) 1996 by Internet Software Consortium. |
4 | * | 4 | * |
@@ -57,6 +57,7 @@ inet_pton(int af, const char *src, void *dst) | |||
57 | } | 57 | } |
58 | /* NOTREACHED */ | 58 | /* NOTREACHED */ |
59 | } | 59 | } |
60 | DEF_WEAK(inet_pton); | ||
60 | 61 | ||
61 | /* int | 62 | /* int |
62 | * inet_pton4(src, dst) | 63 | * inet_pton4(src, dst) |
diff --git a/src/lib/libc/net/res_comp.c b/src/lib/libc/net/res_comp.c index a1467c3dbb..f6f987eb0e 100644 --- a/src/lib/libc/net/res_comp.c +++ b/src/lib/libc/net/res_comp.c | |||
@@ -1,4 +1,4 @@ | |||
1 | /* $OpenBSD: res_comp.c,v 1.16 2015/01/16 18:18:58 millert Exp $ */ | 1 | /* $OpenBSD: res_comp.c,v 1.17 2015/09/13 21:36:08 guenther Exp $ */ |
2 | 2 | ||
3 | /* | 3 | /* |
4 | * ++Copyright++ 1985, 1993 | 4 | * ++Copyright++ 1985, 1993 |
@@ -440,6 +440,7 @@ _getshort(const u_char *msgp) | |||
440 | GETSHORT(u, msgp); | 440 | GETSHORT(u, msgp); |
441 | return (u); | 441 | return (u); |
442 | } | 442 | } |
443 | DEF_STRONG(_getshort); | ||
443 | 444 | ||
444 | #ifdef NeXT | 445 | #ifdef NeXT |
445 | /* | 446 | /* |
@@ -461,6 +462,7 @@ _getlong(const u_char *msgp) | |||
461 | GETLONG(u, msgp); | 462 | GETLONG(u, msgp); |
462 | return (u); | 463 | return (u); |
463 | } | 464 | } |
465 | DEF_STRONG(_getlong); | ||
464 | 466 | ||
465 | void | 467 | void |
466 | __putshort(u_int16_t s, u_char *msgp) | 468 | __putshort(u_int16_t s, u_char *msgp) |