CVS HEAD psql won't let you out of a Password: prompt
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).
regards, tom lane
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@svana.org> http://svana.org/kleptog/
Show quoted text
From each according to his ability. To each according to his ability to litigate.