diff options
author | Georg Brandl <georg@python.org> | 2007-10-24 18:55:37 +0000 |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2007-10-24 18:55:37 +0000 |
commit | bd1c68c94f0d5bc25b48f62c7527f51c754f2b6b (patch) | |
tree | a468fcccf4193f6d26ce71246e2596de6ffc9eec /Lib/struct.py | |
parent | 97f9d4f31224e72e5c714ea7e509c4fd0044f0e2 (diff) | |
download | cpython-git-bd1c68c94f0d5bc25b48f62c7527f51c754f2b6b.tar.gz |
Patch #1303: Adapt str8 constructor to bytes (now buffer) one.
Diffstat (limited to 'Lib/struct.py')
-rw-r--r-- | Lib/struct.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/struct.py b/Lib/struct.py index 027caa258b..10085b713e 100644 --- a/Lib/struct.py +++ b/Lib/struct.py @@ -36,7 +36,7 @@ from _struct import Struct as _Struct, error class Struct(_Struct): def __init__(self, fmt): if isinstance(fmt, str): - fmt = str8(fmt) + fmt = str8(fmt, 'latin1') _Struct.__init__(self, fmt) _MAXCACHE = 100 |