diff options
author | zaxl <zaxl@ffa7fe5e-494d-0410-b361-a75ebd5db220> | 2008-10-22 22:14:46 +0000 |
---|---|---|
committer | zaxl <zaxl@ffa7fe5e-494d-0410-b361-a75ebd5db220> | 2008-10-22 22:14:46 +0000 |
commit | 18b2376b9b2e5c829b8b7f9081ffc81d696d7b5f (patch) | |
tree | c5b4af65857707b77070d95a038cb80c152c308c /navit/plugin.c | |
parent | 355ba90c07aac9608cf989a95a6cb880e04c05d7 (diff) | |
download | navit-18b2376b9b2e5c829b8b7f9081ffc81d696d7b5f.tar.gz |
FIX:core:fix the fix do not crash if plugins are not in config
git-svn-id: http://svn.code.sf.net/p/navit/code/trunk/navit@1538 ffa7fe5e-494d-0410-b361-a75ebd5db220
Diffstat (limited to 'navit/plugin.c')
-rw-r--r-- | navit/plugin.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/navit/plugin.c b/navit/plugin.c index 8650a614f..d3fdf4417 100644 --- a/navit/plugin.c +++ b/navit/plugin.c @@ -260,8 +260,6 @@ plugin_get_type(enum plugin_type type, const char *type_name, const char *name) struct name_val *nv; struct plugin *pl; char *mod_name, *filename=NULL, *corename=NULL; - if (!pls) - return NULL; l=plugin_types[type]; while (l) { nv=l->data; @@ -269,6 +267,8 @@ plugin_get_type(enum plugin_type type, const char *type_name, const char *name) return nv->val; l=g_list_next(l); } + if (!pls) + return NULL; lpls=pls->list; if(!g_ascii_strcasecmp(type_name, "map")) type_name="data"; |