]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Backport of 1.5:
authorJack Jansen <jack.jansen@cwi.nl>
Fri, 25 Oct 2002 20:36:53 +0000 (20:36 +0000)
committerJack Jansen <jack.jansen@cwi.nl>
Fri, 25 Oct 2002 20:36:53 +0000 (20:36 +0000)
Under Jaguar it seems that 'errn' return value keyword parameters don't
(or don't always?) show up with missed(). I think this is a bug in
Jaguar, but as it is a potential dangerous problem (the OSA event has
failed, but the Python code isn't told about this and happily continues)
this is a quick workaround.

Mac/Lib/aetools.py

index ba42f03c1b96c7ea065bcaa114b2b5c187eee241..bf9383c0d3705e9a49ac9e508f6d8aeeac0d0242 100644 (file)
@@ -65,6 +65,14 @@ def unpackevent(ae):
        else:
                parameters['----'] = unpack(dirobj)
                del dirobj
+       # Workaround for what I feel is a bug in OSX 10.2: 'errn' won't show up in missed...
+       try:
+               dirobj = ae.AEGetParamDesc('errn', '****')
+       except AE.Error:
+               pass
+       else:
+               parameters['errn'] = unpack(dirobj, formodulename)
+               del dirobj
        while 1:
                key = missed(ae)
                if not key: break