Skip to content

Commit c6de090

Browse files
authored
Merge pull request #612 from marc1006/master
Some smaller fixes
2 parents 8eeff66 + 2ed8395 commit c6de090

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

mitogen/compat/pkgutil.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -542,7 +542,7 @@ def extend_path(path, name):
542542
if os.path.isfile(pkgfile):
543543
try:
544544
f = open(pkgfile)
545-
except IOError, msg:
545+
except IOError as msg:
546546
sys.stderr.write("Can't open %s: %s\n" %
547547
(pkgfile, msg))
548548
else:

mitogen/master.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -462,7 +462,7 @@ def find(self, fullname):
462462
return None
463463

464464
path = getattr(mod, '__file__', None)
465-
if not (os.path.exists(path) and _looks_like_script(path)):
465+
if not (path is not None and os.path.exists(path) and _looks_like_script(path)):
466466
return None
467467

468468
fp = open(path, 'rb')

mitogen/parent.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2331,7 +2331,7 @@ def disconnect(self, context):
23312331
directly connected.
23322332
"""
23332333
stream = self.stream_by_id(context)
2334-
if stream.remote_id != context.context_id:
2334+
if stream.protocol.remote_id != context.context_id:
23352335
return
23362336

23372337
l = mitogen.core.Latch()

0 commit comments

Comments
 (0)