]> granicus.if.org Git - python/commitdiff
Closes #14452: remove BOM insertion code.
authorVinay Sajip <vinay_sajip@yahoo.co.uk>
Mon, 16 Apr 2012 13:39:53 +0000 (14:39 +0100)
committerVinay Sajip <vinay_sajip@yahoo.co.uk>
Mon, 16 Apr 2012 13:39:53 +0000 (14:39 +0100)
Lib/logging/handlers.py
Misc/NEWS

index 7689b040c6010c295b03b77d240466af1dd3c00f..65b0a2da000b94cac7979c920d4b4f519b9ee8ff 100644 (file)
@@ -808,8 +808,6 @@ class SysLogHandler(logging.Handler):
         prio = prio.encode('utf-8')
         # Message is a string. Convert to bytes as required by RFC 5424
         msg = msg.encode('utf-8')
-        if codecs:
-            msg = codecs.BOM_UTF8 + msg
         msg = prio + msg
         try:
             if self.unixsocket:
index 0a7ea9a7aa0bf49e9dd056a3d46c07d9c39b6663..adb0b08f224fff30fbb64bd7796c22308efc118c 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -43,6 +43,8 @@ Core and Builtins
 Library
 -------
 
+- Issue #14452: SysLogHandler no longer inserts a UTF-8 BOM into the message.
+
 - Issue #13496: Fix potential overflow in bisect.bisect algorithm when applied
   to a collection of size > sys.maxsize / 2.