comparison libpurple/core.c @ 26150:f95aa2b14bec

propagate from branch 'im.pidgin.pidgin' (head 96db74f0ccbe2a283893e33f0f7bff5a827f48d9) to branch 'im.pidgin.pidgin.vv' (head 55aa623e09a7429df54b4e068dcba4c67c5fe779)
author Mike Ruprecht <maiku@soc.pidgin.im>
date Fri, 30 Jan 2009 08:58:07 +0000
parents fc8fd4fef166
children 8c8948b9f602 1b8c18ab762f
comparison
equal deleted inserted replaced
26149:a6e53d23bcbb 26150:f95aa2b14bec
135 135
136 /* Since plugins get probed so early we should probably initialize their 136 /* Since plugins get probed so early we should probably initialize their
137 * subsystem right away too. 137 * subsystem right away too.
138 */ 138 */
139 purple_plugins_init(); 139 purple_plugins_init();
140 140
141 /* Initialize all static protocols. */ 141 /* Initialize all static protocols. */
142 static_proto_init(); 142 static_proto_init();
143 143
144 purple_plugins_probe(G_MODULE_SUFFIX); 144 purple_plugins_probe(G_MODULE_SUFFIX);
145 145
196 purple_signal_emit(purple_get_core(), "quitting"); 196 purple_signal_emit(purple_get_core(), "quitting");
197 197
198 /* Transmission ends */ 198 /* Transmission ends */
199 purple_connections_disconnect_all(); 199 purple_connections_disconnect_all();
200 200
201 /*
202 * Certificates must be destroyed before the SSL plugins, because
203 * PurpleCertificates contain pointers to PurpleCertificateSchemes,
204 * and the PurpleCertificateSchemes will be unregistered when the
205 * SSL plugin is uninit.
206 */
207 purple_certificate_uninit();
208
209 /* The SSL plugins must be uninit before they're unloaded */
210 purple_ssl_uninit();
211
212 /* Unload all plugins before the UI because UI plugins might call
213 * UI-specific functions */
214 purple_debug_info("main", "Unloading all plugins\n");
215 purple_plugins_destroy_all();
216
217 /* Shut down the UI before all the subsystems */
218 ops = purple_core_get_ui_ops();
219 if (ops != NULL && ops->quit != NULL)
220 ops->quit();
221
201 /* Save .xml files, remove signals, etc. */ 222 /* Save .xml files, remove signals, etc. */
202 purple_smileys_uninit(); 223 purple_smileys_uninit();
203 purple_idle_uninit(); 224 purple_idle_uninit();
204 purple_ssl_uninit();
205 purple_pounces_uninit(); 225 purple_pounces_uninit();
206 purple_blist_uninit(); 226 purple_blist_uninit();
207 purple_ciphers_uninit(); 227 purple_ciphers_uninit();
208 purple_notify_uninit(); 228 purple_notify_uninit();
209 purple_conversations_uninit(); 229 purple_conversations_uninit();
210 purple_connections_uninit(); 230 purple_connections_uninit();
211 purple_certificate_uninit();
212 purple_buddy_icons_uninit(); 231 purple_buddy_icons_uninit();
213 purple_accounts_uninit(); 232 purple_accounts_uninit();
214 purple_savedstatuses_uninit(); 233 purple_savedstatuses_uninit();
215 purple_status_uninit(); 234 purple_status_uninit();
216 purple_prefs_uninit();
217 purple_sound_uninit(); 235 purple_sound_uninit();
218 purple_xfers_uninit(); 236 purple_xfers_uninit();
219 purple_proxy_uninit(); 237 purple_proxy_uninit();
220 purple_dnsquery_uninit(); 238 purple_dnsquery_uninit();
221 purple_imgstore_uninit(); 239 purple_imgstore_uninit();
222 purple_network_uninit(); 240 purple_network_uninit();
223 241
224 purple_debug_info("main", "Unloading all plugins\n"); 242 /* Everything after this must not try to read any prefs */
225 purple_plugins_destroy_all(); 243 purple_prefs_uninit();
226
227 ops = purple_core_get_ui_ops();
228 if (ops != NULL && ops->quit != NULL)
229 ops->quit();
230
231 purple_plugins_uninit(); 244 purple_plugins_uninit();
232 #ifdef HAVE_DBUS 245 #ifdef HAVE_DBUS
233 purple_dbus_uninit(); 246 purple_dbus_uninit();
234 #endif 247 #endif
235 248
236 purple_cmds_uninit(); 249 purple_cmds_uninit();
250 /* Everything after this cannot try to write things to the confdir */
237 purple_util_uninit(); 251 purple_util_uninit();
238 252
239 purple_signals_uninit(); 253 purple_signals_uninit();
240 254
241 g_free(core->ui); 255 g_free(core->ui);