Re: oid2name core dump
| От | Michael Fuhr |
|---|---|
| Тема | Re: oid2name core dump |
| Дата | |
| Msg-id | 20041202045513.GA60677@winnie.fuhr.org обсуждение исходный текст |
| Ответ на | oid2name core dump (Michael Fuhr <mike@fuhr.org>) |
| Список | pgsql-bugs |
On Wed, Dec 01, 2004 at 09:41:49PM -0700, Michael Fuhr wrote:
> The warnings are coming from these two lines (around lines 448 and 449):
>
> free(comma_oids);
> free(comma_tables);
>
> Apparently the values of comma_oids and comma_tables are bogus.
> I haven't looked more closely yet to see why.
main() initializes my_opts->oids->num and my_opts->tables->num to 0.
sql_exec_searchtables() later sets comma_oids and comma_tables with
the following code:
comma_oids = get_comma_elts(opts->oids);
comma_tables = get_comma_elts(opts->tables);
get_comma_elts() starts with the following:
if (eary->num == 0)
return "";
sql_exec_searchtables() later tries to free the pointers to "".
Program fall down go boom.
--
Michael Fuhr
http://www.fuhr.org/~mfuhr/
В списке pgsql-bugs по дате отправления: