Re: NULL handling in exconfig deconstruction - Mailing list pgsql-hackers

From Tom Lane
Subject Re: NULL handling in exconfig deconstruction
Date
Msg-id 22978.1542041453@sss.pgh.pa.us
Whole thread Raw
In response to NULL handling in exconfig deconstruction  (Daniel Gustafsson <daniel@yesql.se>)
List pgsql-hackers
Daniel Gustafsson <daniel@yesql.se> writes:
> In extension_config_remove() we first ensure that pg_extension.extconfig cannot
> contain any NULL values in the array, ERRORing out if so.  Later we however ask
> for NULL values back when deconstructing the array, throwing away the results
> knowing there wont be any, which seems superfluous (and wrong if there indeed
> were any).  The attached patch signals to deconstruct_array() that any NULL
> values should be considered an error instead of returned, to keep NULL value
> handling consistent (and shave two small allocations off).

LGTM, pushed.

            regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: BUG #15212: Default values in partition tables don't work as expected and allow NOT NULL violation
Next
From: Tom Lane
Date:
Subject: Re: [HACKERS] [PATCH v2] Add and report the new "session_read_only" GUC pseudo-variable.