From eac0706761e628532ffcd27f3e4d7fa559a5f818 Mon Sep 17 00:00:00 2001 From: Peter Rajnoha Date: Wed, 29 Jun 2016 15:58:14 +0200 Subject: [PATCH] libdm: do not issue 'Failed to create directory' message for failure in dm_create_dir There are detailed messages inside _create_dir_recursive that dm_create_dir calls (except EROFS which where the message is not generated, like anywhere else in the code). --- libdm/libdm-file.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libdm/libdm-file.c b/libdm/libdm-file.c index 986782413..2c313b300 100644 --- a/libdm/libdm-file.c +++ b/libdm/libdm-file.c @@ -97,10 +97,8 @@ int dm_create_dir(const char *dir) if (stat(dir, &info) == 0 && S_ISDIR(info.st_mode)) return 1; - if (!_create_dir_recursive(dir)) { - log_error("Failed to create directory %s.", dir); - return 0; - } + if (!_create_dir_recursive(dir)) + return_0; return 1; }