Re: concerns around pg_lsn
От | Jeevan Ladhe |
---|---|
Тема | Re: concerns around pg_lsn |
Дата | |
Msg-id | CAOgcT0MSytis68KA=xbHS7BnSyD2aY_2VV+8xDaB3uPJOLDjcg@mail.gmail.com обсуждение исходный текст |
Ответ на | Re: concerns around pg_lsn (Jeevan Ladhe <jeevan.ladhe@enterprisedb.com>) |
Список | pgsql-hackers |
Hi Michael,
What is more dangerous with float8in_internal_opt_error() is, it hasthe have_error flag, which is never ever set or used in that function. Furthermore risks are - the callers of this function e.g. executeItemOptUnwrapTarget()are passing a non-null pointer to it(default set to false) and expect to throwan error if it sees some error during float8in_internal_opt_error(), *but*float8in_internal_opt_error() has actually never touched the have_error flag.
My bad, I see there's this macro call in float8in_internal_opt_error() and that
set the flag:
{code}
#define RETURN_ERROR(throw_error) \
do { \
if (have_error) { \
*have_error = true; \
return 0.0; \
} else { \
throw_error; \
} \
} while (0)
{code}
My patch on way, thanks.
Regards,
Jeevan Ladhe
В списке pgsql-hackers по дате отправления: