libpq and psql not on same page about SIGPIPE - Mailing list pgsql-hackers

From Tom Lane
Subject libpq and psql not on same page about SIGPIPE
Date
Msg-id 8831.1100537696@sss.pgh.pa.us
Whole thread Raw
Responses Re: libpq and psql not on same page about SIGPIPE  (Bruce Momjian <pgman@candle.pha.pa.us>)
List pgsql-hackers
libpq compiled with --enable-thread-safety thinks it can set the SIGPIPE
signal handler.  It thinks once is enough.

psql thinks it can arbitrarily flip the signal handler between SIG_IGN
and SIG_DFL.  Ergo, after the first use of the pager for output, libpq's
SIGPIPE handling will be broken.

I submit that psql is unlikely to be the only program that does this,
and therefore that libpq must be considered broken, not psql.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Robert Treat
Date:
Subject: Re: Update TIP 9 please
Next
From: "Bort, Paul"
Date:
Subject: Re: psql \e broken again