Re: CVS HEAD psql won't let you out of a Password: prompt

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: CVS HEAD psql won't let you out of a Password: prompt
Date: 2006-09-26 18:48:09
Message-ID: 20060926184809.GD19913@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Sep 26, 2006 at 11:58:27AM -0400, Tom Lane wrote:
> If psql wants a Password:, it won't gracefully give up in response to
> ^C, ^D, or ^J ... you *must* enter a nonempty string before you can get
> your console back. This is pretty unfriendly, and I don't recall prior
> versions behaving that way (though I so seldom use a password with PG
> that I might be wrong).

For ^C it may have been a side-effect of the SIGINT changes, though I
doubt it. One of the first things psql does is setup a ^C handler and
it only ever did a siglongjmp in that case. But there was no setjmp
done at that point, so a ^C would have been a no-op.

psql uses simple_prompt which I beleive comes from the port directory.
And there is definitly a loop there to retry on no input. That hasn't
changed any time recently as far as I can tell.

Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Hannu Krosing 2006-09-26 19:24:27 Re: Please to technical check of upcoming release
Previous Message Tom Lane 2006-09-26 18:18:59 Sane error messages for SSL retry cases