diff options
author | Sergey Poznyakoff <gray@Pirx.gnu.org.ua> | 2009-04-27 17:23:50 +0300 |
---|---|---|
committer | Sergey Poznyakoff <gray@Pirx.gnu.org.ua> | 2009-04-27 17:23:50 +0300 |
commit | 4d22b4e8668cc717440d66120b8607be9a273c97 (patch) | |
tree | 93b4addac108a1c8e913f0d5c68cb513f5c82c31 /src/stat.c | |
parent | fe8f5226e8bc39bdc75e40e1c1ea464e9fc60ad3 (diff) | |
download | tagr-4d22b4e8668cc717440d66120b8607be9a273c97.tar.gz tagr-4d22b4e8668cc717440d66120b8607be9a273c97.tar.bz2 |
Bugfixes.
* src/main.c (change_user): Bugfix
(main): Reset user to the value of user_option, if set.
Fix (again) log_to_stderr initialization.
Switch to user privileges before actually performing any
actions that modify the database and other output files.
* src/report.c (open_db): Don't exit if unable to open
database. Return 1 instead. All callers updated.
* src/tagr.h (open_db): Update prototype.
Diffstat (limited to 'src/stat.c')
-rw-r--r-- | src/stat.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -428,3 +428,4 @@ import (const char *dirname) { - open_db (TAGR_DB_WR); + if (open_db (TAGR_DB_WR)) + exit (EX_UNAVAILABLE); if (import_log (dirname) == 0) @@ -447,3 +448,4 @@ import (const char *dirname) case 0: - open_db (TAGR_DB_WR); + if (open_db (TAGR_DB_WR)) + exit (EX_UNAVAILABLE); for (i = 0; i < gl.gl_pathc; i++) |