diff options
author | Just van Rossum <just@letterror.com> | 2002-01-03 12:16:18 (GMT) |
---|---|---|
committer | Just van Rossum <just@letterror.com> | 2002-01-03 12:16:18 (GMT) |
commit | 8edfc542f098f98754a959d3414238eab152cb88 (patch) | |
tree | 73d8c327e508c5dfe34594e3458741abfbe62e49 /Mac | |
parent | ad4f532f6532cc099ba5665e3553394db907796c (diff) | |
download | cpython-8edfc542f098f98754a959d3414238eab152cb88.zip cpython-8edfc542f098f98754a959d3414238eab152cb88.tar.gz cpython-8edfc542f098f98754a959d3414238eab152cb88.tar.bz2 |
The output MenuRef of GetMenuItemHierarchicalMenu() may be NULL.
Diffstat (limited to 'Mac')
-rw-r--r-- | Mac/Modules/menu/_Menumodule.c | 2 | ||||
-rw-r--r-- | Mac/Modules/menu/menuscan.py | 2 |
2 files changed, 3 insertions, 1 deletions
diff --git a/Mac/Modules/menu/_Menumodule.c b/Mac/Modules/menu/_Menumodule.c index 3395b4d..f46eb83 100644 --- a/Mac/Modules/menu/_Menumodule.c +++ b/Mac/Modules/menu/_Menumodule.c @@ -1638,7 +1638,7 @@ static PyObject *MenuObj_GetMenuItemHierarchicalMenu(MenuObject *_self, PyObject &outHierMenu); if (_err != noErr) return PyMac_Error(_err); _res = Py_BuildValue("O&", - MenuObj_New, outHierMenu); + OptMenuObj_New, outHierMenu); return _res; } #endif diff --git a/Mac/Modules/menu/menuscan.py b/Mac/Modules/menu/menuscan.py index ef2d2f8..11be8f2 100644 --- a/Mac/Modules/menu/menuscan.py +++ b/Mac/Modules/menu/menuscan.py @@ -144,6 +144,8 @@ class MyScanner(Scanner): ([("void", "*", "OutMode"), ("long", "*", "InMode"), ("long", "*", "OutMode")], [("VarVarOutBuffer", "*", "InOutMode")]), + ([("MenuRef", 'outHierMenu', "OutMode")], + [("OptMenuRef", 'outHierMenu', "OutMode")]), ] def writeinitialdefs(self): |