Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
cb7ea291
Kaydet (Commit)
cb7ea291
authored
May 24, 2010
tarafından
Vinay Sajip
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue #8795: logging: Backported trunk fix for SysLogHandler and Unicode.
üst
c28d554d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
10 additions
and
0 deletions
+10
-0
handlers.py
Lib/logging/handlers.py
+10
-0
No files found.
Lib/logging/handlers.py
Dosyayı görüntüle @
cb7ea291
...
...
@@ -31,6 +31,11 @@ try:
import
codecs
except
ImportError
:
codecs
=
None
try
:
unicode
_unicode
=
True
except
NameError
:
_unicode
=
False
#
# Some constants...
...
...
@@ -777,6 +782,11 @@ class SysLogHandler(logging.Handler):
self
.
encodePriority
(
self
.
facility
,
self
.
mapPriority
(
record
.
levelname
)),
msg
)
# Treat unicode messages as required by RFC 5424
if
_unicode
and
type
(
msg
)
is
unicode
:
msg
=
msg
.
encode
(
'utf-8'
)
if
codecs
:
msg
=
codecs
.
BOM_UTF8
+
msg
try
:
if
self
.
unixsocket
:
try
:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment