vlc/vlc-3.0 | branch: master | Lyndon Brown <jnq...@gmail.com> | Thu Apr 25 04:11:43 2019 +0100| [49a7ef8bab0e7afb507efff9740856ca4a7fada6] | committer: David Fuhrmann
macosx: fix handling of null sub category items in prefs tree construction subCategoryItem would be null if: a) a plugin author neglected to place a set_category() call before one or more options. b) the first or only subcat targetted by a plugin is a general one. there are actual examples of A with a handful of in-tree plugins (to be fixed in a subsequent commit). there are multiple in-tree modules which target general subcats, including various logger and keystore plugins. Signed-off-by: Felix Paul Kühne <fe...@feepk.net> (backport of 7c2f535afe995702fe6f7dd2bb17820541006caa) Signed-off-by: David Fuhrmann <dfuhrm...@videolan.org> > http://git.videolan.org/gitweb.cgi/vlc/vlc-3.0.git/?a=commit;h=49a7ef8bab0e7afb507efff9740856ca4a7fada6 --- modules/gui/macosx/prefs.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/modules/gui/macosx/prefs.m b/modules/gui/macosx/prefs.m index 2d3f2e8d89..ddb91f6966 100644 --- a/modules/gui/macosx/prefs.m +++ b/modules/gui/macosx/prefs.m @@ -535,7 +535,7 @@ } } else if (!module_is_main(p_module) && (CONFIG_ITEM(configType) || configType == CONFIG_SECTION)) { - if (![[subCategoryItem children] containsObject: pluginItem]) { + if (subCategoryItem && ![[subCategoryItem children] containsObject: pluginItem]) { [[subCategoryItem children] addObject:pluginItem]; } _______________________________________________ vlc-commits mailing list vlc-commits@videolan.org https://mailman.videolan.org/listinfo/vlc-commits