aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJason Woodward2011-04-29 14:32:14 +0000
committerJason Woodward2011-04-29 14:32:14 +0000
commit1ed8c54bd92c1b3423510cf68929e8a5a1aa3feb (patch)
tree6791d13988076742057a5fa8082d42afc6440abc /src
parent0b25ace123cfcc9cdc32b5b144b1356a2112d5cf (diff)
downloadslapt-get-1ed8c54bd92c1b3423510cf68929e8a5a1aa3feb.tar.gz
silence chdir return warning
Diffstat (limited to 'src')
-rw-r--r--src/configuration.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/configuration.c b/src/configuration.c
index a0b209e..12c087e 100644
--- a/src/configuration.c
+++ b/src/configuration.c
@@ -142,15 +142,15 @@ slapt_rc_config *slapt_read_rc_config(const char *file_name)
void slapt_working_dir_init(const slapt_rc_config *global_config)
{
DIR *working_dir;
- int mode = W_OK;
+ int mode = W_OK, r;
char *cwd = NULL;
if ( (working_dir = opendir(global_config->working_dir)) == NULL ) {
cwd = getcwd (NULL, 0);
if (cwd != NULL) {
- chdir ("/");
+ r = chdir ("/");
slapt_create_dir_structure (global_config->working_dir);
- chdir (cwd);
+ r = chdir (cwd);
free (cwd);
} else {
printf (gettext ("Failed to build working directory [%s]\n"),