summaryrefslogtreecommitdiff
path: root/libdm/libdm-common.c
diff options
context:
space:
mode:
authorPeter Rajnoha <prajnoha@redhat.com>2013-08-15 12:23:49 +0200
committerPeter Rajnoha <prajnoha@redhat.com>2013-08-15 12:23:49 +0200
commit0563bd0037610397c5838d0172fd1c913c62c187 (patch)
tree445ecf1a15793c1ca90febbdfd9d90ab88f6a756 /libdm/libdm-common.c
parent8cbbe851a80e8d99dc886ce9b44834137731d8ce (diff)
downloadlvm2-0563bd0037610397c5838d0172fd1c913c62c187.tar.gz
fix: some issues reported by coverity
- null_fd resource leak on error path in _reopen_fd_null fn - dead code in verify_message in clvmd code - dead code in _init_filter_components in toolcontext code - null dereference in dm_prepare_selinux_context on error path if setfscreatecon fails while resetting SELinux context
Diffstat (limited to 'libdm/libdm-common.c')
-rw-r--r--libdm/libdm-common.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libdm/libdm-common.c b/libdm/libdm-common.c
index 2e068dc3b..4f398f112 100644
--- a/libdm/libdm-common.c
+++ b/libdm/libdm-common.c
@@ -880,7 +880,7 @@ int dm_prepare_selinux_context(const char *path, mode_t mode)
log_debug_activation("Resetting SELinux context to default value.");
if (setfscreatecon(scontext) < 0) {
- log_sys_error("setfscreatecon", path);
+ log_sys_error("setfscreatecon", path ? : "SELinux context reset");
freecon(scontext);
return 0;
}