Re: psql bug - Mailing list pgsql-hackers

From Teodor Sigaev
Subject Re: psql bug
Date
Msg-id 4FB55BBD.5000700@sigaev.ru
Whole thread Raw
In response to Re: psql bug  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: psql bug
List pgsql-hackers
> FWIW, I failed to reproduce that on any of my machines.  Maybe
> your editor is leaving the tty in a funny state?

Seems system() call cleanups sigaction state on FreeBSD. I've modify
void
setup_cancel_handler(void)
{    fprintf(stderr, "%p -> %p\n", pqsignal(SIGINT, handle_sigint), handle_sigint);
}

and add it around system() call. Next:

% export EDITOR=echo
% psql postgres
0x0 -> 0x409620
SET
Timing is on.
psql (9.2beta1)
Type "help" for help.

postgres=# \e
0x409620 -> 0x409620
/tmp/psql.edit.7997.sql
0x0 -> 0x409620
postgres=#

-- 
Teodor Sigaev                                   E-mail: teodor@sigaev.ru
  WWW: http://www.sigaev.ru/
 


pgsql-hackers by date:

Previous
From: Joshua Berkus
Date:
Subject: Re: Strange issues with 9.2 pg_basebackup & replication
Next
From: Miroslav Šimulčík
Date:
Subject: Re: temporal support patch