Commit 4d61cf9d authored by Peter W. Draper's avatar Peter W. Draper
Browse files

We also require that directories can be searched, so make that explicit

This is a requirement of fopen()
parent f0639090
......@@ -387,11 +387,12 @@ int main(int argc, char *argv[]) {
/* Check that we can write the snapshots by testing if the output
* directory exists and is writable. */
* directory exists and is searchable and writable. */
char basename[PARSER_MAX_LINE_SIZE];
parser_get_param_string(params, "Snapshots:basename", basename);
const char *dirp = dirname(basename);
if (access(dirp, W_OK) != 0) {
message("dirp = %s", dirp);
if (access(dirp, W_OK|X_OK) != 0) {
error("Cannot write snapshots in directory %s (%s)", dirp,
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment