soc.2012.statscollector: 003eec1d: Check PurplePluginType for checking STAN...

sanket at sanketagarwal.com sanket at sanketagarwal.com
Mon May 14 13:27:50 EDT 2012


----------------------------------------------------------------------
Revision: 003eec1d7af1ba5154275fde41ef07f3ee3cace9
Parent:   4332203bdc21ec17e5fbfbfdf6f5d0e58b490599
Author:   sanket at sanketagarwal.com
Date:     05/13/12 12:53:49
Branch:   im.pidgin.soc.2012.statscollector
URL: http://d.pidgin.im/viewmtn/revision/info/003eec1d7af1ba5154275fde41ef07f3ee3cace9

Changelog: 

Check PurplePluginType for checking STANDARD plugins

Changes against parent 4332203bdc21ec17e5fbfbfdf6f5d0e58b490599

  patched  pidgin/plugins/statscollector.c

-------------- next part --------------
============================================================
--- pidgin/plugins/statscollector.c	48cd2ea5fb7fb10bf30eba8bdb32c1050bc2d0e6
+++ pidgin/plugins/statscollector.c	07b784ef72c4c99edbb24f6a768503b585eee9cc
@@ -111,17 +111,23 @@ plugin_load_event(PurplePlugin *plugin){
 
   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