diff options
author | Jelmer Vernooij <jelmer@samba.org> | 2007-10-05 18:03:01 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 15:07:47 -0500 |
commit | 719a4ae0d32ab9ba817fd01f2b8f4cba220a8c60 (patch) | |
tree | 5235b8d927cdb765432398df1af8ce9ca9ddf4bf /source4/lib/socket/interface.c | |
parent | 42bdfc3f6ce61fcd4f0d31c48dee470b62a9d59b (diff) | |
download | samba-719a4ae0d32ab9ba817fd01f2b8f4cba220a8c60.tar.gz samba-719a4ae0d32ab9ba817fd01f2b8f4cba220a8c60.tar.bz2 samba-719a4ae0d32ab9ba817fd01f2b8f4cba220a8c60.zip |
r25522: Convert to standard bool types.
(This used to be commit 5e814287ba475e12f8cc934fdd09b199dcdfdb86)
Diffstat (limited to 'source4/lib/socket/interface.c')
-rw-r--r-- | source4/lib/socket/interface.c | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/source4/lib/socket/interface.c b/source4/lib/socket/interface.c index a30e4b8af7..9ca4450581 100644 --- a/source4/lib/socket/interface.c +++ b/source4/lib/socket/interface.c @@ -54,7 +54,7 @@ static struct ipv4_addr tov4(struct in_addr in) /**************************************************************************** Try and find an interface that matches an ip. If we cannot, return NULL **************************************************************************/ -static struct interface *iface_find(struct in_addr ip, BOOL CheckMask) +static struct interface *iface_find(struct in_addr ip, bool CheckMask) { struct interface *i; if (is_zero_ip(tov4(ip))) return local_interfaces; @@ -321,7 +321,7 @@ const char *iface_best_ip(const char *dest) load_interfaces(); ip.s_addr = interpret_addr(dest); - iface = iface_find(ip, True); + iface = iface_find(ip, true); if (iface) { return iface->ip_s; } @@ -329,25 +329,25 @@ const char *iface_best_ip(const char *dest) } /** - return True if an IP is one one of our local networks + return true if an IP is one one of our local networks */ -BOOL iface_is_local(const char *dest) +bool iface_is_local(const char *dest) { struct in_addr ip; load_interfaces(); ip.s_addr = interpret_addr(dest); - if (iface_find(ip, True)) { - return True; + if (iface_find(ip, true)) { + return true; } - return False; + return false; } /** - return True if a IP matches a IP/netmask pair + return true if a IP matches a IP/netmask pair */ -BOOL iface_same_net(const char *ip1, const char *ip2, const char *netmask) +bool iface_same_net(const char *ip1, const char *ip2, const char *netmask) { return same_net(interpret_addr2(ip1), interpret_addr2(ip2), |