diff --git a/daemon/libvirtd.c b/daemon/libvirtd.c index b1539b10d3..e6d73cc142 100644 --- a/daemon/libvirtd.c +++ b/daemon/libvirtd.c @@ -3103,10 +3103,6 @@ int main(int argc, char **argv) { exit(EXIT_FAILURE); } - /* Set error logging priority to debug, so client errors don't - * show up as errors in the daemon log */ - virErrorSetLogPriority(VIR_LOG_DEBUG); - while (1) { int optidx = 0; int c; diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms index c7e4772250..003fc63d31 100644 --- a/src/libvirt_private.syms +++ b/src/libvirt_private.syms @@ -918,7 +918,6 @@ virAuditSend; # virterror_internal.h virDispatchError; virErrorMsg; -virErrorSetLogPriority; virRaiseErrorFull; virReportErrorHelper; virReportOOMErrorFull; diff --git a/src/util/virterror.c b/src/util/virterror.c index 3dd6256f50..91302846b5 100644 --- a/src/util/virterror.c +++ b/src/util/virterror.c @@ -26,7 +26,6 @@ virThreadLocal virLastErr; virErrorFunc virErrorHandler = NULL; /* global error handler */ void *virUserData = NULL; /* associated data */ -static int virErrorLogPriority = -1; /* * Macro used to format the message as a string in virRaiseError @@ -725,13 +724,8 @@ virRaiseErrorFull(virConnectPtr conn ATTRIBUTE_UNUSED, /* * Hook up the error or warning to the logging facility * XXXX should we include filename as 'category' instead of domain name ? - * - * When an explicit error log priority is set then use it, otherwise - * translate the error level to the log priority. This is used by libvirtd - * to log client errors at debug priority. */ - priority = virErrorLogPriority == -1 ? virErrorLevelPriority(level) - : virErrorLogPriority; + priority = virErrorLevelPriority(level); virLogMessage(virErrorDomainName(domain), priority, funcname, linenr, 1, "%s", str); @@ -1341,9 +1335,3 @@ void virReportOOMErrorFull(int domcode, domcode, VIR_ERR_NO_MEMORY, VIR_ERR_ERROR, virerr, NULL, NULL, -1, -1, virerr, NULL); } - -void -virErrorSetLogPriority(int priority) -{ - virErrorLogPriority = priority; -} diff --git a/src/util/virterror_internal.h b/src/util/virterror_internal.h index 2dd2b4aff4..601a88472f 100644 --- a/src/util/virterror_internal.h +++ b/src/util/virterror_internal.h @@ -89,6 +89,5 @@ void virReportOOMErrorFull(int domcode, int virSetError(virErrorPtr newerr); void virDispatchError(virConnectPtr conn); const char *virStrerror(int theerrno, char *errBuf, size_t errBufLen); -void virErrorSetLogPriority(int priority); #endif