]> granicus.if.org Git - postgresql/commitdiff
Fix function calls to INET/CIDR functions. Added cidr_out.
authorBruce Momjian <bruce@momjian.us>
Thu, 22 Oct 1998 00:35:28 +0000 (00:35 +0000)
committerBruce Momjian <bruce@momjian.us>
Thu, 22 Oct 1998 00:35:28 +0000 (00:35 +0000)
src/backend/utils/adt/inet.c
src/include/catalog/pg_proc.h
src/include/catalog/pg_type.h
src/include/utils/builtins.h

index d096c664d3321ebc693a4867faed51b8d58a541f..c755678cbc7b2578ed224c5646408a9c7e8ad579 100644 (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.9 1998/10/21 16:06:45 momjian Exp $
+ *     $Id: inet.c,v 1.10 1998/10/22 00:35:23 momjian Exp $
  *     Jon Postel RIP 16 Oct 1998
  */
 
@@ -148,6 +148,13 @@ cidr_in(char *src)
        return (dst);
 }
 
+/* just a stub */
+char *
+cidr_out(inet *src)
+{
+       return inet_out(src);
+}
+
 /*
  *     Boolean tests for magnitude.  Add V4/V6 testing!
  */
index 08eea066d2c9a50113f4bf0f85dfaf8a28af4419..ef6d067199c25e4c66984cf3bc139d44ff402b43 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: pg_proc.h,v 1.76 1998/10/21 21:14:20 momjian Exp $
+ * $Id: pg_proc.h,v 1.77 1998/10/22 00:35:25 momjian Exp $
  *
  * NOTES
  *       The script catalog/genbki.sh reads this file and generates .bki
@@ -2077,6 +2077,8 @@ DESCR("(internal)");
 /* for cidr type support */
 DATA(insert OID = 1267 (  cidr_in           PGUID 11 f t f 1 f 650 "0" 100 0 0 100  foo bar ));
 DESCR("(internal)");
+DATA(insert OID = 1416 (  cidr_out                     PGUID 11 f t f 1 f 23 "0" 100 0 0 100  foo bar ));
+DESCR("(internal)");
 
 /* these are used for both inet and cidr */
 DATA(insert OID = 920 (  inet_eq                  PGUID 11 f t f 2 f 16 "869 869" 100 0 0 100  foo bar ));
@@ -2113,23 +2115,23 @@ DATA(insert OID = 682 (  inet_host                      PGUID 11 f t f 1 f 25 "869" 100 0 0 100  fo
 DESCR("host address");
 
 /* inet versions */
-DATA(insert OID = 940 (  netmask               PGUID 14 f t f 1 f 25 "869" 100 0 0 100  "select inet_netmask($1)" - ));
+DATA(insert OID = 946 (  netmask               PGUID 14 f t f 1 f 25 "869" 100 0 0 100  "select inet_netmask($1)" - ));
 DESCR("netmask of address");
-DATA(insert OID = 941 (  netmasklen            PGUID 14 f t f 1 f 23 "869" 100 0 0 100  "select inet_netmasklen($1)" - ));
+DATA(insert OID = 947 (  netmasklen            PGUID 14 f t f 1 f 23 "869" 100 0 0 100  "select inet_netmasklen($1)" - ));
 DESCR("netmask length");
-DATA(insert OID = 945 (  broadcast             PGUID 14 f t f 1 f 25 "869" 100 0 0 100  "select inet_broadcast($1)" - ));
+DATA(insert OID = 948 (  broadcast             PGUID 14 f t f 1 f 25 "869" 100 0 0 100  "select inet_broadcast($1)" - ));
 DESCR("broadcast address");
-DATA(insert OID = 682 (  host                  PGUID 14 f t f 1 f 25 "869" 100 0 0 100  "select inet_host($1)" - ));
+DATA(insert OID = 949 (  host                  PGUID 14 f t f 1 f 25 "869" 100 0 0 100  "select inet_host($1)" - ));
 DESCR("host address");
 
 /* cidr versions */
-DATA(insert OID = 940 (  netmask               PGUID 14 f t f 1 f 25 "650" 100 0 0 100  "select inet_netmask($1)" - ));
+DATA(insert OID = 696 (  netmask               PGUID 14 f t f 1 f 25 "650" 100 0 0 100  "select inet_netmask($1)" - ));
 DESCR("netmask of address");
-DATA(insert OID = 941 (  netmasklen            PGUID 14 f t f 1 f 23 "650" 100 0 0 100  "select inet_netmasklen($1)" - ));
+DATA(insert OID = 697 (  netmasklen            PGUID 14 f t f 1 f 23 "650" 100 0 0 100  "select inet_netmasklen($1)" - ));
 DESCR("netmask length");
-DATA(insert OID = 945 (  broadcast             PGUID 14 f t f 1 f 25 "650" 100 0 0 100  "select inet_broadcast($1)" - ));
+DATA(insert OID = 698 (  broadcast             PGUID 14 f t f 1 f 25 "650" 100 0 0 100  "select inet_broadcast($1)" - ));
 DESCR("broadcast address");
-DATA(insert OID = 682 (  host                  PGUID 14 f t f 1 f 25 "650" 100 0 0 100  "select inet_host($1)" - ));
+DATA(insert OID = 699 (  host                  PGUID 14 f t f 1 f 25 "650" 100 0 0 100  "select inet_host($1)" - ));
 DESCR("host address");
 
 
index 03a90370ac77f955125e6b97011b40ab7b543705..4b8884fd47b1fb038cfd2aabed2200aaab9cca47 100644 (file)
@@ -7,7 +7,7 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: pg_type.h,v 1.50 1998/10/21 16:06:48 momjian Exp $
+ * $Id: pg_type.h,v 1.51 1998/10/22 00:35:26 momjian Exp $
  *
  * NOTES
  *       the genbki.sh script reads this file and generates .bki
@@ -302,7 +302,7 @@ DATA(insert OID = 829 ( macaddr        PGUID  6 -1 f b t \054 0     0 macaddr_in macaddr
 DESCR("MAC address");
 DATA(insert OID = 869 ( inet      PGUID  -1 -1 f b t \054 0 0 inet_in inet_out inet_in inet_out i _null_ ));
 DESCR("Host address");
-DATA(insert OID = 650 ( cidr      PGUID  -1 -1 f b t \054 0 0 cidr_in inet_out cidr_in inet_out i _null_ ));
+DATA(insert OID = 650 ( cidr      PGUID  -1 -1 f b t \054 0 0 cidr_in cidr_out cidr_in cidr_out i _null_ ));
 DESCR("Network address");
 
 /* OIDS 900 - 999 */
index f6048b76b613178ce18fe376a77a2c938034ff4d..4144b54fcb470695c6b65fad1813b22944dada0c 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Copyright (c) 1994, Regents of the University of California
  *
- * $Id: builtins.h,v 1.63 1998/10/21 16:06:49 momjian Exp $
+ * $Id: builtins.h,v 1.64 1998/10/22 00:35:28 momjian Exp $
  *
  * NOTES
  *       This should normally only be included by fmgr.h.
@@ -520,6 +520,7 @@ int inet_cidr_pton(int af, const void *src, void *dst, size_t size, int *used);
 
 /* cidr.c */
 inet      *cidr_in(char *str);
+char      *cidr_out(inet *addr);
 
 /* inet.c */
 inet      *inet_in(char *str);