Skip to content

Commit 0e6652e

Browse files
committed
psql cleanup
1 parent 2323b63 commit 0e6652e

29 files changed

+5236
-8021
lines changed

src/bin/psql/command.c

Lines changed: 1049 additions & 904 deletions
Large diffs are not rendered by default.

src/bin/psql/command.h

Lines changed: 30 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -11,39 +11,36 @@
1111

1212

1313

14-
typedef enum _backslashResult {
15-
CMD_UNKNOWN = 0, /* not done parsing yet (internal only) */
16-
CMD_SEND, /* query complete; send off */
17-
CMD_SKIP_LINE, /* keep building query */
18-
CMD_TERMINATE, /* quit program */
19-
CMD_NEWEDIT, /* query buffer was changed (e.g., via \e) */
20-
CMD_ERROR /* the execution of the backslash command resulted
21-
in an error */
22-
} backslashResult;
23-
24-
25-
26-
backslashResult
27-
HandleSlashCmds(PsqlSettings *pset,
28-
const char *line,
29-
PQExpBuffer query_buf,
30-
const char ** end_of_cmd);
31-
32-
bool
33-
do_connect(const char *new_dbname,
34-
const char *new_user,
35-
PsqlSettings *pset);
36-
37-
bool
38-
process_file(const char *filename,
39-
PsqlSettings *pset);
40-
41-
42-
bool
43-
do_pset(const char * param,
44-
const char * value,
45-
printQueryOpt * popt,
46-
bool quiet);
14+
typedef enum _backslashResult
15+
{
16+
CMD_UNKNOWN = 0, /* not done parsing yet (internal only) */
17+
CMD_SEND, /* query complete; send off */
18+
CMD_SKIP_LINE, /* keep building query */
19+
CMD_TERMINATE, /* quit program */
20+
CMD_NEWEDIT, /* query buffer was changed (e.g., via \e) */
21+
CMD_ERROR /* the execution of the backslash command
22+
* resulted in an error */
23+
} backslashResult;
24+
25+
26+
27+
backslashResult HandleSlashCmds(PsqlSettings *pset,
28+
const char *line,
29+
PQExpBuffer query_buf,
30+
const char **end_of_cmd);
31+
32+
bool do_connect(const char *new_dbname,
33+
const char *new_user,
34+
PsqlSettings *pset);
35+
36+
bool process_file(const char *filename,
37+
PsqlSettings *pset);
38+
39+
40+
bool do_pset(const char *param,
41+
const char *value,
42+
printQueryOpt * popt,
43+
bool quiet);
4744

4845

4946
#endif

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy