indexer bumping: check the status of touch command to avoid cc warning

This commit is contained in:
Jean-Francois Dockes 2018-11-30 12:13:12 +01:00
parent abc45bc156
commit 02181fbb84
2 changed files with 11 additions and 4 deletions

View File

@ -502,9 +502,13 @@ static void lockorexit(Pidfile *pidfile, RclConfig *config)
string cmd("touch "); string cmd("touch ");
string path = path_cat(config->getConfDir(), "recoll.conf"); string path = path_cat(config->getConfDir(), "recoll.conf");
cmd += path; cmd += path;
system(cmd.c_str()); int status;
cerr << "Monitoring indexer process was notified of " if ((status = system(cmd.c_str()))) {
"indexing request\n"; cerr << cmd << " failed with status " << status << endl;
} else {
cerr << "Monitoring indexer process was notified of "
"indexing request\n";
}
} }
#endif #endif
} else { } else {

View File

@ -303,7 +303,10 @@ void RclMain::bumpIndexing()
string cmd("touch "); string cmd("touch ");
string path = path_cat(theconfig->getConfDir(), "recoll.conf"); string path = path_cat(theconfig->getConfDir(), "recoll.conf");
cmd += path; cmd += path;
system(cmd.c_str()); int status;
if ((status = system(cmd.c_str()))) {
cerr << cmd << " failed with status " << status << endl;
}
} }
} }
#else #else