issue #576: fix Kwargs minor version check.

Unicode kwargs were introduced in Python 2.6.5, not 2.6.0.
This commit is contained in:
David Wilson 2019-04-03 19:01:56 +01:00
parent 333151f7fd
commit ee62c57c9d
2 changed files with 8 additions and 4 deletions

View File

@ -27,13 +27,17 @@ Fixes
* `#557 <https://github.com/dw/mitogen/issues/557>`_: fix a crash when running * `#557 <https://github.com/dw/mitogen/issues/557>`_: fix a crash when running
on machines with high CPU counts. on machines with high CPU counts.
* `#570 <https://github.com/dw/mitogen/issues/570>`_: the ``firewalld`` module
internally caches a dbus name that changes across ``firewalld`` restarts,
causing a failure if the service is restarted between ``firewalld`` module invocations.
* `#575 <https://github.com/dw/mitogen/issues/575>`_: fix a crash when * `#575 <https://github.com/dw/mitogen/issues/575>`_: fix a crash when
rendering an error message to indicate no usable temporary directories could rendering an error message to indicate no usable temporary directories could
be found. be found.
* `#570 <https://github.com/dw/mitogen/issues/570>`_: the ``firewalld`` module * `#576 <https://github.com/dw/mitogen/issues/576>`_: fix a crash during
internally caches a dbus name that changes across ``firewalld`` restarts, startup on SuSE Linux 11, due to an incorrect version compatibility check in
causing a failure if the service is restarted between ``firewalld`` module invocations. the Mitogen code.
Thanks! Thanks!

View File

@ -277,7 +277,7 @@ class Kwargs(dict):
self[k.decode()] = v self[k.decode()] = v
else: else:
self[k] = v self[k] = v
elif sys.version_info < (2, 6): elif sys.version_info < (2, 6, 5):
def __init__(self, dct): def __init__(self, dct):
for k, v in dct.iteritems(): for k, v in dct.iteritems():
if type(k) is unicode: if type(k) is unicode: