/soc/2012/sanket/statscollector-2.x.y: 7bbf3a0b8b9d: Check Purpl...

Sanket Agarwal sanket at soc.pidgin.im
Tue Jul 10 00:36:21 EDT 2012


Changeset: 7bbf3a0b8b9de5036ba039f1aeb2ecfddd23ab9f
Author:	 Sanket Agarwal <sanket at soc.pidgin.im>
Date:	 2012-05-13 16:53 +0000
Branch:	 soc.2012.statscollector
URL: http://hg.pidgin.im/soc/2012/sanket/statscollector-2.x.y/rev/7bbf3a0b8b9d

Description:

Check PurplePluginType for checking STANDARD plugins

diffstat:

 pidgin/plugins/statscollector.c |  10 ++++++++--
 1 files changed, 8 insertions(+), 2 deletions(-)

diffs (29 lines):

diff --git a/pidgin/plugins/statscollector.c b/pidgin/plugins/statscollector.c
--- a/pidgin/plugins/statscollector.c
+++ b/pidgin/plugins/statscollector.c
@@ -111,17 +111,23 @@
 
   char *plugin_id, *data;
   xmlnode *plugin_xml, *p_id;
+  PurplePluginType plugin_type;
 
   plugin_id = purple_plugin_get_id(plugin);
 
+  plugin_type = (PurplePluginType) plugin->info->type;
+
+  purple_debug_info("STATS", "Plugin %s %d\n", plugin_id, plugin_type);
+
+
   /* check if the account already exist in our XML file */
 
   if(g_hash_table_lookup(stats_plugins_ht, plugin_id))
     purple_debug_info("STATS", "Plugin %s already exists!", plugin_id);
 
-  else if(g_str_has_prefix(plugin_id, "prpl"))
+  else if(plugin_type != PURPLE_PLUGIN_STANDARD)
     /* We don't need no prpl plugins */
-    purple_debug_info("STATS", "Plugin %s is a prpl plugin\n", plugin_id);
+    purple_debug_info("STATS", "Plugin %s is *not* a standard plugin\n", plugin_id);
 
   else{
 



More information about the Commits mailing list