chantra / rpms / rpm

Forked from rpms/rpm 2 years ago
Clone
467d1d
--- rpm-4.14.3/plugins/selinux.c.orig	2020-05-11 16:07:22.873791795 +0200
467d1d
+++ rpm-4.14.3/plugins/selinux.c	2020-05-11 16:10:11.701771157 +0200
467d1d
@@ -47,7 +47,7 @@
467d1d
 
467d1d
     sehandle = selabel_open(SELABEL_CTX_FILE, opts, 1);
467d1d
 
467d1d
-    rpmlog(RPMLOG_DEBUG, "selabel_open: (%s) %s\n",
467d1d
+    rpmlog((sehandle == NULL) ? RPMLOG_ERR : RPMLOG_DEBUG, "selabel_open: (%s) %s\n",
467d1d
 	   path, (sehandle == NULL ? strerror(errno) : ""));
467d1d
 
467d1d
     return (sehandle != NULL) ? RPMRC_OK : RPMRC_FAIL;