blob: b2e5c54953522009df7396723e931d922a66fda4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
$NetBSD: patch-ab,v 1.1 2007/11/30 20:09:36 rillig Exp $
On NetBSD, struct ifconf.ifc_buf is a void *.
--- asmtpd/synfp.C.orig 2005-10-19 23:52:26.000000000 +0000
+++ asmtpd/synfp.C 2007-11-30 20:06:43.000000000 +0000
@@ -86,7 +86,7 @@ synfp::ifnames (vec<str> *ifs, in_addr t
for (str *sp = ifs->base (); sp < ifs->lim (); sp++)
seen.insert (*sp);
- char *p = ifc.ifc_buf, *e = p + ifc.ifc_len;
+ char *p = static_cast<char *>(ifc.ifc_buf), *e = p + ifc.ifc_len;
while (p < e) {
struct ifreq *ifrp = (struct ifreq *) p;
struct ifreq ifr = *ifrp;
@@ -151,7 +151,7 @@ synfp::ifaddrs (vec<in_addr> *addrs, str
for (in_addr *ap = addrs->base (); ap < addrs->lim (); ap++)
seen.insert (*ap);
- char *p = ifc.ifc_buf, *e = p + ifc.ifc_len;
+ char *p = static_cast<char *>(ifc.ifc_buf), *e = p + ifc.ifc_len;
while (p < e) {
struct ifreq *ifrp = (struct ifreq *) p;
struct ifreq ifr = *ifrp;
|