Re: Current enums patch - Mailing list pgsql-patches

From Tom Dunstan
Subject Re: Current enums patch
Date
Msg-id 4610fc98.15a.35d1.23451@internode.on.net
Whole thread Raw
In response to Current enums patch  (Tom Dunstan <pgsql@tomd.cc>)
Responses Re: Current enums patch  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-patches
> Looks like we need to check the length on type creation
> too.
>
> I'll fix later if not beaten to it.

It works for me (ie fails with an appropriate error) locally
on Linux FC6 x86-64. Perhaps this platform initializes
memory to zero on allocation? I dunno. Anyway, if you can
reproduce it, please have a go, I'm at work and won't be
able to do anything more in depth for some time.

I could have sworn that I had some bounds checking in there
at one point, but it doesn't seem to be in the latest
version of the code. *shrug*. It should be both in
cstring_enum() in enum.c and in DefineEnum() in typecmds.c.

Cheers

Tom

pgsql-patches by date:

Previous
From: "Pavan Deolasee"
Date:
Subject: HOT WIP Patch - version 6.3
Next
From: "Simon Riggs"
Date:
Subject: Re: Blocked post