|
5 | 5 | * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group
|
6 | 6 | * Portions Copyright (c) 1994, Regents of the University of California
|
7 | 7 | *
|
8 |
| - * $PostgreSQL: pgsql/src/bin/scripts/vacuumdb.c,v 1.4 2003/11/29 19:52:07 pgsql Exp $ |
| 8 | + * $PostgreSQL: pgsql/src/bin/scripts/vacuumdb.c,v 1.5 2004/01/01 19:27:15 tgl Exp $ |
9 | 9 | *
|
10 | 10 | *-------------------------------------------------------------------------
|
11 | 11 | */
|
|
14 | 14 | #include "common.h"
|
15 | 15 |
|
16 | 16 |
|
17 |
| -static |
18 |
| -void |
19 |
| -vacuum_one_database(const char *dbname, bool full, bool verbose, bool analyze, const char *table, |
20 |
| - const char *host, const char *port, const char *username, bool password, |
| 17 | +static void |
| 18 | +vacuum_one_database(const char *dbname, bool full, bool verbose, bool analyze, |
| 19 | + const char *table, |
| 20 | + const char *host, const char *port, |
| 21 | + const char *username, bool password, |
21 | 22 | const char *progname, bool echo, bool quiet);
|
22 |
| -static |
23 |
| -void |
| 23 | +static void |
24 | 24 | vacuum_all_databases(bool full, bool verbose, bool analyze,
|
25 |
| - const char *host, const char *port, const char *username, bool password, |
| 25 | + const char *host, const char *port, |
| 26 | + const char *username, bool password, |
26 | 27 | const char *progname, bool echo, bool quiet);
|
27 | 28 |
|
28 | 29 | static void help(const char *progname);
|
@@ -168,10 +169,11 @@ main(int argc, char *argv[])
|
168 | 169 | }
|
169 | 170 |
|
170 | 171 |
|
171 |
| -static |
172 |
| -void |
173 |
| -vacuum_one_database(const char *dbname, bool full, bool verbose, bool analyze, const char *table, |
174 |
| - const char *host, const char *port, const char *username, bool password, |
| 172 | +static void |
| 173 | +vacuum_one_database(const char *dbname, bool full, bool verbose, bool analyze, |
| 174 | + const char *table, |
| 175 | + const char *host, const char *port, |
| 176 | + const char *username, bool password, |
175 | 177 | const char *progname, bool echo, bool quiet)
|
176 | 178 | {
|
177 | 179 | PQExpBufferData sql;
|
@@ -215,14 +217,17 @@ vacuum_one_database(const char *dbname, bool full, bool verbose, bool analyze, c
|
215 | 217 | termPQExpBuffer(&sql);
|
216 | 218 |
|
217 | 219 | if (!quiet)
|
| 220 | + { |
218 | 221 | puts("VACUUM");
|
| 222 | + fflush(stdout); |
| 223 | + } |
219 | 224 | }
|
220 | 225 |
|
221 | 226 |
|
222 |
| -static |
223 |
| -void |
| 227 | +static void |
224 | 228 | vacuum_all_databases(bool full, bool verbose, bool analyze,
|
225 |
| - const char *host, const char *port, const char *username, bool password, |
| 229 | + const char *host, const char *port, |
| 230 | + const char *username, bool password, |
226 | 231 | const char *progname, bool echo, bool quiet)
|
227 | 232 | {
|
228 | 233 | PGconn *conn;
|
|
0 commit comments