Re: psql bug

From: Teodor Sigaev <teodor(at)sigaev(dot)ru>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Pgsql Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: psql bug
Date: 2012-05-17 20:12:45
Message-ID: 4FB55BBD.5000700@sigaev.ru
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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(at)sigaev(dot)ru
WWW: http://www.sigaev.ru/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Miroslav Šimulčík 2012-05-18 07:06:58 Re: temporal support patch
Previous Message Joshua Berkus 2012-05-17 18:57:33 Re: Strange issues with 9.2 pg_basebackup & replication