1
0
mirror of https://github.com/postgres/postgres.git synced 2025-12-12 02:37:31 +03:00

Here's some changes I made last night to psql's common.c (as found in

7.3.2).  It removes some code duplication and #ifdeffing, and some
unstructured ugliness such as tacky breaks and an unneeded continue.
Breaks up a large function into smaller functions and reduces required
nesting levels, and kills a variable or two.

Jeroen T. Vermeulen
This commit is contained in:
Bruce Momjian
2003-03-20 06:00:12 +00:00
parent 94701fb24b
commit be1c6e7529
6 changed files with 366 additions and 236 deletions

View File

@@ -3,7 +3,7 @@
*
* Copyright 2000 by PostgreSQL Global Development Group
*
* $Header: /cvsroot/pgsql/src/bin/psql/common.h,v 1.22 2003/03/18 22:15:44 petere Exp $
* $Header: /cvsroot/pgsql/src/bin/psql/common.h,v 1.23 2003/03/20 06:00:12 momjian Exp $
*/
#ifndef COMMON_H
#define COMMON_H
@@ -29,6 +29,8 @@ extern char *simple_prompt(const char *prompt, int maxlen, bool echo);
extern volatile bool cancel_pressed;
extern PGconn *cancelConn;
extern void ResetCancelConn(void);
#ifndef WIN32
extern void handle_sigint(SIGNAL_ARGS);
#endif /* not WIN32 */