/dev/twasilczyk/imgupload: d94f3563172b: Revert unnecessary API ...

Tomasz Wasilczyk twasilczyk at pidgin.im
Mon May 19 04:44:04 EDT 2014


Changeset: d94f3563172b1e12ca253580d4080c9a0cab0a65
Author:	 Tomasz Wasilczyk <twasilczyk at pidgin.im>
Date:	 2014-05-19 10:43 +0200
Branch:	 default
URL: https://hg.pidgin.im/dev/twasilczyk/imgupload/rev/d94f3563172b

Description:

Revert unnecessary API changes

diffstat:

 libpurple/plugin.c |  21 ---------------------
 libpurple/plugin.h |  24 ------------------------
 2 files changed, 0 insertions(+), 45 deletions(-)

diffs (85 lines):

diff --git a/libpurple/plugin.c b/libpurple/plugin.c
--- a/libpurple/plugin.c
+++ b/libpurple/plugin.c
@@ -184,32 +184,12 @@ purple_plugin_new(gboolean native, const
 
 	plugin->native_plugin = native;
 	plugin->path = g_strdup(path);
-	plugin->extra_data = g_hash_table_new_full(g_str_hash, g_str_equal,
-		g_free, NULL);
 
 	PURPLE_DBUS_REGISTER_POINTER(plugin, PurplePlugin);
 
 	return plugin;
 }
 
-void
-purple_plugin_set_data(PurplePlugin *plugin, const gchar *key, gpointer value)
-{
-	g_return_if_fail(plugin != NULL);
-	g_return_if_fail(plugin->extra_data != NULL);
-
-	g_hash_table_insert(plugin->extra_data, g_strdup(key), value);
-}
-
-gpointer
-purple_plugin_get_data(PurplePlugin *plugin, const gchar *key)
-{
-	g_return_val_if_fail(plugin != NULL, NULL);
-	g_return_val_if_fail(plugin->extra_data != NULL, NULL);
-
-	return g_hash_table_lookup(plugin->extra_data, key);
-}
-
 PurplePlugin *
 purple_plugin_probe(const char *filename)
 {
@@ -896,7 +876,6 @@ purple_plugin_destroy(PurplePlugin *plug
 
 	g_free(plugin->path);
 	g_free(plugin->error);
-	g_hash_table_destroy(plugin->extra_data);
 
 	PURPLE_DBUS_UNREGISTER_POINTER(plugin);
 
diff --git a/libpurple/plugin.h b/libpurple/plugin.h
--- a/libpurple/plugin.h
+++ b/libpurple/plugin.h
@@ -187,7 +187,6 @@ struct _PurplePlugin
 	gboolean unloadable;
 	GList *dependent_plugins;
 	gpointer ui_data;
-	GHashTable *extra_data;
 
 	/*< private >*/
 	void (*_purple_reserved1)(void);
@@ -298,29 +297,6 @@ GType purple_plugin_get_type(void);
 PurplePlugin *purple_plugin_new(gboolean native, const char *path);
 
 /**
- * purple_plugin_set_data:
- * @plugin: The plugin.
- * @key:    The data key.
- * @value:  The data to set.
- *
- * Sets extra data for particular plugin.
- */
-void
-purple_plugin_set_data(PurplePlugin *plugin, const gchar *key, gpointer value);
-
-/**
- * purple_plugin_get_data:
- * @plugin: The plugin.
- * @key:    The data key.
- *
- * Gets extra data for particular plugin.
- *
- * Returns: data set previously with #purple_plugin_set_data.
- */
-gpointer
-purple_plugin_get_data(PurplePlugin *plugin, const gchar *key);
-
-/**
  * purple_plugin_probe:
  * @filename: The plugin's filename.
  *



More information about the Commits mailing list