|
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(constchar*dbname,boolfull,boolverbose,boolanalyze,constchar*table, |
20 |
| -constchar*host,constchar*port,constchar*username,boolpassword, |
| 17 | +staticvoid |
| 18 | +vacuum_one_database(constchar*dbname,boolfull,boolverbose,boolanalyze, |
| 19 | +constchar*table, |
| 20 | +constchar*host,constchar*port, |
| 21 | +constchar*username,boolpassword, |
21 | 22 | constchar*progname,boolecho,boolquiet);
|
22 |
| -static |
23 |
| -void |
| 23 | +staticvoid |
24 | 24 | vacuum_all_databases(boolfull,boolverbose,boolanalyze,
|
25 |
| -constchar*host,constchar*port,constchar*username,boolpassword, |
| 25 | +constchar*host,constchar*port, |
| 26 | +constchar*username,boolpassword, |
26 | 27 | constchar*progname,boolecho,boolquiet);
|
27 | 28 |
|
28 | 29 | staticvoidhelp(constchar*progname);
|
@@ -168,10 +169,11 @@ main(int argc, char *argv[])
|
168 | 169 | }
|
169 | 170 |
|
170 | 171 |
|
171 |
| -static |
172 |
| -void |
173 |
| -vacuum_one_database(constchar*dbname,boolfull,boolverbose,boolanalyze,constchar*table, |
174 |
| -constchar*host,constchar*port,constchar*username,boolpassword, |
| 172 | +staticvoid |
| 173 | +vacuum_one_database(constchar*dbname,boolfull,boolverbose,boolanalyze, |
| 174 | +constchar*table, |
| 175 | +constchar*host,constchar*port, |
| 176 | +constchar*username,boolpassword, |
175 | 177 | constchar*progname,boolecho,boolquiet)
|
176 | 178 | {
|
177 | 179 | PQExpBufferDatasql;
|
@@ -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 | +staticvoid |
224 | 228 | vacuum_all_databases(boolfull,boolverbose,boolanalyze,
|
225 |
| -constchar*host,constchar*port,constchar*username,boolpassword, |
| 229 | +constchar*host,constchar*port, |
| 230 | +constchar*username,boolpassword, |
226 | 231 | constchar*progname,boolecho,boolquiet)
|
227 | 232 | {
|
228 | 233 | PGconn*conn;
|
|