Re: [HACKERS] psql and Control-C

From: Chris Bitmead <chrisb(at)nimrod(dot)itg(dot)telstra(dot)com(dot)au>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: PostgreSQL Development <pgsql-hackers(at)postgreSQL(dot)org>
Subject: Re: [HACKERS] psql and Control-C
Date: 2000-02-17 23:34:09
Message-ID: 38AC8571.1306E0B8@nimrod.itg.telecom.com.au
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut wrote:
>
> Some people have indicated that they don't like how psql currently handles
> Control-C if no query is in progress. I consider the behaviour of the
> shells desirable but, quite frankly, I don't know how to do it.

The typical way to do this sort of thing is to longjmp back to the main
loop. And I think if you look at sig.c in bash, this is probably what
they are doing.

> Actually, shouldn't a Ctrl-C in a script cancel the query *and* stop the
> script at all times?

Yes.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Chris Bitmead 2000-02-17 23:38:42 Re: [HACKERS] FYI: BNF for SQL93 and SQL-3
Previous Message Marc Tardif 2000-02-17 23:27:50 queries on 2+ indices