libpurple/protocols/sametime/sametime.c

changeset 39526
4f678f514b69
parent 39523
415b0705e48b
child 39665
2172e3b8eeef
child 39669
bab07ecb9330
equal deleted inserted replaced
39525:e1280f3aaea8 39526:4f678f514b69
27 #include <stdlib.h> 27 #include <stdlib.h>
28 #include <time.h> 28 #include <time.h>
29 29
30 /* glib includes */ 30 /* glib includes */
31 #include <glib.h> 31 #include <glib.h>
32 #include <gmime/gmime.h>
32 33
33 /* purple includes */ 34 /* purple includes */
34 #include "account.h" 35 #include "account.h"
35 #include "accountopt.h" 36 #include "accountopt.h"
36 #include "action.h" 37 #include "action.h"
5359 5360
5360 /* redirect meanwhile's logging to purple's */ 5361 /* redirect meanwhile's logging to purple's */
5361 log_handler[1] = g_log_set_handler("meanwhile", logflags, 5362 log_handler[1] = g_log_set_handler("meanwhile", logflags,
5362 mw_log_handler, NULL); 5363 mw_log_handler, NULL);
5363 5364
5365 g_mime_init();
5366
5364 return TRUE; 5367 return TRUE;
5365 } 5368 }
5366 5369
5367 5370
5368 static gboolean 5371 static gboolean
5369 plugin_unload(PurplePlugin *plugin, GError **error) 5372 plugin_unload(PurplePlugin *plugin, GError **error)
5370 { 5373 {
5374 g_mime_shutdown();
5375
5371 g_log_remove_handler(G_LOG_DOMAIN, log_handler[0]); 5376 g_log_remove_handler(G_LOG_DOMAIN, log_handler[0]);
5372 g_log_remove_handler("meanwhile", log_handler[1]); 5377 g_log_remove_handler("meanwhile", log_handler[1]);
5373 5378
5374 if (!purple_protocols_remove(my_protocol, error)) 5379 if (!purple_protocols_remove(my_protocol, error))
5375 return FALSE; 5380 return FALSE;

mercurial