Re: [HACKERS] [sqlsmith] crash in RestoreLibraryState during low-memory testing - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [HACKERS] [sqlsmith] crash in RestoreLibraryState during low-memory testing
Date
Msg-id 18852.1507007778@sss.pgh.pa.us
Whole thread Raw
In response to Re: [HACKERS] [sqlsmith] crash in RestoreLibraryState duringlow-memory testing  (Amit Kapila <amit.kapila16@gmail.com>)
Responses Re: [HACKERS] [sqlsmith] crash in RestoreLibraryState during low-memory testing
List pgsql-hackers
Amit Kapila <amit.kapila16@gmail.com> writes:
> Any other ideas?

Given that the crash is so far down inside __dlopen(), and that there's
a clear reference to the string we presumably passed to that:

#11 0x00007f518485e489 in _dl_open (file=0x55b692f2d2b0 "/home/smith/postgres/inst/master/lib/pgcrypto.so",
mode=-2147483390,caller_dlopen=0x55b691cb4c7e < 

I don't actually believe that this is Postgres' fault.  I suspect that
what we're looking at here is a low-memory bug in dlopen itself, probably
something strdup'ing an input string and forgetting to check for a null
result.

Presumably somebody could dig into the libc source code and prove or
disprove this, though it would sure help to know exactly what platform
and version Andreas is testing on.
        regards, tom lane


--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

pgsql-hackers by date:

Previous
From: Ashutosh Bapat
Date:
Subject: Re: [HACKERS] Transactions involving multiple postgres foreign servers
Next
From: Andres Freund
Date:
Subject: Re: [HACKERS] 64-bit queryId?