diff options
| author | Tom Lane | 2006-01-26 02:35:51 +0000 |
|---|---|---|
| committer | Tom Lane | 2006-01-26 02:35:51 +0000 |
| commit | 8d8bf127605d0a87b22bb07e630a075506ca5e1e (patch) | |
| tree | 3ad06ce423081f23df826753da0dc7f998e58822 /src/include/utils/inet.h | |
| parent | 5997386a0a38f3ded28ce6eb2c2b4f110b377e46 (diff) | |
Clean up the INET-vs-CIDR situation. Get rid of the internal is_cidr flag
and rely exclusively on the SQL type system to tell the difference between
the types. Prevent creation of invalid CIDR values via casting from INET
or set_masklen() --- both of these operations now silently zero any bits
to the right of the netmask. Remove duplicate CIDR comparison operators,
letting the type rely on the INET operators instead.
Diffstat (limited to 'src/include/utils/inet.h')
| -rw-r--r-- | src/include/utils/inet.h | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/include/utils/inet.h b/src/include/utils/inet.h index 03b8ee4b7ed..ad6215d7726 100644 --- a/src/include/utils/inet.h +++ b/src/include/utils/inet.h @@ -7,7 +7,7 @@ * Portions Copyright (c) 1996-2005, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/utils/inet.h,v 1.21 2006/01/23 21:45:47 momjian Exp $ + * $PostgreSQL: pgsql/src/include/utils/inet.h,v 1.22 2006/01/26 02:35:51 tgl Exp $ * *------------------------------------------------------------------------- */ @@ -22,7 +22,6 @@ typedef struct { unsigned char family; /* PGSQL_AF_INET or PGSQL_AF_INET6 */ unsigned char bits; /* number of bits in netmask */ - bool is_cidr; /* is cidr? */ unsigned char ipaddr[16]; /* up to 128 bits of address */ } inet_struct; |
