summaryrefslogtreecommitdiff
path: root/ext/_yaml.pyx
diff options
context:
space:
mode:
authorxi <xi@18f92427-320e-0410-9341-c67f048884a3>2009-08-31 08:47:05 +0000
committerxi <xi@18f92427-320e-0410-9341-c67f048884a3>2009-08-31 08:47:05 +0000
commit85760a2ea558ac3d4c23bef019e12600e553048a (patch)
tree4fe033c1af7e5a0d8dcff193ab24aca20023a874 /ext/_yaml.pyx
parentb64c663aed57a578a28bd4575bf4d30630c598e8 (diff)
downloadpyyaml-85760a2ea558ac3d4c23bef019e12600e553048a.tar.gz
Fixed another encoding issue.
git-svn-id: http://svn.pyyaml.org/pyyaml/trunk@366 18f92427-320e-0410-9341-c67f048884a3
Diffstat (limited to 'ext/_yaml.pyx')
-rw-r--r--ext/_yaml.pyx2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/_yaml.pyx b/ext/_yaml.pyx
index ac56b5f..df19492 100644
--- a/ext/_yaml.pyx
+++ b/ext/_yaml.pyx
@@ -955,7 +955,7 @@ cdef class CEmitter:
self.stream = stream
self.dump_unicode = 0
if PY_MAJOR_VERSION < 3:
- if hasattr(stream, 'encoding'):
+ if getattr3(stream, 'encoding', None):
self.dump_unicode = 1
else:
if hasattr(stream, u'encoding'):