diff options
-rw-r--r-- | epan/plugins.c | 10 | ||||
-rw-r--r-- | epan/plugins.h | 7 |
2 files changed, 8 insertions, 9 deletions
diff --git a/epan/plugins.c b/epan/plugins.c index 79a4306fe1..c2edfda9b3 100644 --- a/epan/plugins.c +++ b/epan/plugins.c @@ -313,7 +313,7 @@ plugins_scan_dir(const char *dirname) /* get the global plugin dir */ /* Return value is malloced so the caller should g_free() it. */ -const char *get_plugins_global_dir(const char *plugin_dir) +char *get_plugins_global_dir(const char *plugin_dir) { #ifdef _WIN32 char *install_plugin_dir; @@ -365,7 +365,7 @@ const char *get_plugins_global_dir(const char *plugin_dir) /* get the personal plugin dir */ /* Return value is malloced so the caller should g_free() it. */ -const char *get_plugins_pers_dir(void) +char *get_plugins_pers_dir(void) { return get_persconffile_path(PLUGINS_DIR_NAME, FALSE); } @@ -376,7 +376,7 @@ const char *get_plugins_pers_dir(void) void init_plugins(const char *plugin_dir) { - const char *datafile_dir; + char *datafile_dir; if (plugin_list == NULL) /* ensure init_plugins is only run once */ { @@ -385,14 +385,14 @@ init_plugins(const char *plugin_dir) */ datafile_dir = get_plugins_global_dir(plugin_dir); plugins_scan_dir(datafile_dir); - g_free((char *) datafile_dir); + g_free(datafile_dir); /* * Scan the users plugin directory. */ datafile_dir = get_plugins_pers_dir(); plugins_scan_dir(datafile_dir); - g_free((char *) datafile_dir); + g_free(datafile_dir); } } diff --git a/epan/plugins.h b/epan/plugins.h index e314f45f0c..f844703d9f 100644 --- a/epan/plugins.h +++ b/epan/plugins.h @@ -4,10 +4,9 @@ * $Id$ * * Ethereal - Network traffic analyzer - * By Gerald Combs <gerald@zing.org> + * By Gerald Combs <gerald@ethereal.com> * Copyright 1999 Gerald Combs * - * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License * as published by the Free Software Foundation; either version 2 @@ -46,10 +45,10 @@ extern void register_all_plugin_handoffs(void); /* get the global plugin dir */ /* Return value is g_malloced so the caller should g_free() it. */ -extern const char *get_plugins_global_dir(const char *plugin_dir); +extern char *get_plugins_global_dir(const char *plugin_dir); /* get the personal plugin dir */ /* Return value is g_malloced so the caller should g_free() it. */ -extern const char *get_plugins_pers_dir(void); +extern char *get_plugins_pers_dir(void); #endif /* __PLUGINS_H__ */ |