1
0
mirror of https://github.com/postgres/postgres.git synced 2025-11-10 17:42:29 +03:00

Fix for funcs on INET/CIDR.

This commit is contained in:
Bruce Momjian
1998-10-22 04:58:11 +00:00
parent 2ba4ee74aa
commit 3fe6a77f91
3 changed files with 47 additions and 9 deletions

View File

@@ -3,7 +3,7 @@
* is for IP V4 CIDR notation, but prepared for V6: just
* add the necessary bits where the comments indicate.
*
* $Id: inet.c,v 1.10 1998/10/22 00:35:23 momjian Exp $
* $Id: inet.c,v 1.11 1998/10/22 04:58:07 momjian Exp $
* Jon Postel RIP 16 Oct 1998
*/
@@ -355,12 +355,24 @@ inet_host(inet *ip)
return (ret);
}
text *
cidr_host(inet *ip)
{
inet_host(ip);
}
int4
inet_netmasklen(inet *ip)
{
return ip_bits(ip);
}
int4
cidr_netmasklen(inet *ip)
{
return inet_netmasklen(ip);
}
text *
inet_broadcast(inet *ip)
{
@@ -402,6 +414,12 @@ inet_broadcast(inet *ip)
return (ret);
}
text *
cidr_broadcast(inet *ip)
{
inet_broadcast(ip);
}
text *
inet_netmask(inet *ip)
{
@@ -441,6 +459,12 @@ inet_netmask(inet *ip)
return (ret);
}
text *
cidr_netmask(inet *ip)
{
inet_netmask(ip);
}
/*
* Bitwise comparison for V4 addresses. Add V6 implementation!
*/