Hi,
On 2022-08-23 20:36:55 -0700, Andres Freund wrote:
> Running the ecpg regression tests interactively (to try to find a different
> issue), triggered a crash on windows due to an uninitialized variable (after
> pressing "ignore" in that stupid gui window that we've only disabled for the
> backend).
>
> "The variable 'replace_val' is being used without being initialized."
Looks to me like that's justified. The paths in dttofmtasc_replace using
PGTYPES_TYPE_NOTHING don't set replace_val, but call pgtypes_fmt_replace() -
with replace_val passed by value. If that's the first replacement, an
unitialized variable is passed...
Seems either the caller should skip calling pgtypes_fmt_replace() in the
NOTHING case, or replace_val should be zero initialized?
- Andres