diff options
Diffstat (limited to 'src/core/execute.c')
-rw-r--r-- | src/core/execute.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/core/execute.c b/src/core/execute.c index 0fe084f211..2012cd596a 100644 --- a/src/core/execute.c +++ b/src/core/execute.c @@ -2164,11 +2164,12 @@ static int setup_exec_directory( } } else { r = mkdir_label(p, context->directories[type].mode); - if (r < 0 && r != -EEXIST) - goto fail; - if (r == -EEXIST) { + if (r < 0) { struct stat st; + if (r != -EEXIST) + goto fail; + if (stat(p, &st) < 0) { r = -errno; goto fail; |