瀏覽代碼

Ticket 47982 - HR Log timers, regression fix for subsystem logging

Bug Description:  In the introduction of HR log times subsystem was omitted
from the errors log.

Fix Description:  Re-add the subsystem parameter to subsystem logging.

https://fedorahosted.org/389/ticket/47982

Author: wibrown

Review by: mreynolds (Thanks!)
William Brown 9 年之前
父節點
當前提交
6858dfd409
共有 1 個文件被更改,包括 6 次插入1 次删除
  1. 6 1
      ldap/servers/slapd/log.c

+ 6 - 1
ldap/servers/slapd/log.c

@@ -2289,7 +2289,12 @@ vslapd_log_error(
 
     /* blen = strlen(buffer); */
     /* This truncates again .... But we have the nice smprintf above! */
-    PR_snprintf (buffer+blen, sizeof(buffer)-blen, "%s", vbuf);
+    if (subsystem == NULL) {
+        PR_snprintf (buffer+blen, sizeof(buffer)-blen, "%s", vbuf);
+    } else {
+        PR_snprintf (buffer+blen, sizeof(buffer)-blen, "%s - %s", subsystem, vbuf);
+    }
+
     buffer[sizeof(buffer)-1] = '\0';
 
     if (fp)