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

index 6bbc1f71b6ee7309cbf1318a0130e5e7a7236bf7..0eb36f3f22061d47a31ed64f30a17b419711d02f 100644 (file)
@@ -821,8 +821,6 @@ class SysLogHandler(logging.Handler):
         # Message is a string. Convert to bytes as required by RFC 5424
         if type(msg) is unicode:
             msg = msg.encode('utf-8')
-            if codecs:
-                msg = codecs.BOM_UTF8 + msg
         msg = prio + msg
         try:
             if self.unixsocket:
index e35b9f3df31cfe3f8dbb0a172d56aa4e16791029..71218d7f4a4b3464e2a4054c7c90147df8fac352 100644 (file)
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -48,6 +48,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.