diff src/toc.c @ 1118:e1078ee286ba

[gaim-migrate @ 1128] don't send the config on signoff, because we may be signing off because the connection died, in which case sendig the config would cause a SIGPIPE and gaim would exit (it happened to me). committer: Tailor Script <tailor@pidgin.im>
author Eric Warmenhoven <eric@warmenhoven.org>
date Tue, 21 Nov 2000 10:13:39 +0000
parents c61f9c384413
children 028295b1f1b3
line wrap: on
line diff
--- a/src/toc.c	Tue Nov 21 09:50:31 2000 +0000
+++ b/src/toc.c	Tue Nov 21 10:13:39 2000 +0000
@@ -47,7 +47,7 @@
 #include "pixmaps/dt_icon.xpm"
 #include "pixmaps/free_icon.xpm"
 
-#define REVISION "gaim:$Revision: 1124 $"
+#define REVISION "gaim:$Revision: 1128 $"
 
 #define TYPE_SIGNON    1
 #define TYPE_DATA      2
@@ -99,7 +99,6 @@
 
 static void toc_callback(gpointer, gint, GdkInputCondition);
 static unsigned char *roast_password(char *);
-int sflap_send(struct gaim_connection *, char *, int, int);
 
 /* ok. this function used to take username/password, and return 0 on success.
  * now, it takes username/password, and returns NULL on error or a new gaim_connection
@@ -153,15 +152,7 @@
 	set_login_progress(gc, 2, buf);
 }
 
-static void toc_set_config(struct gaim_connection *gc) {
-	char buf[MSG_LEN], snd[MSG_LEN];
-	toc_build_config(gc, buf, MSG_LEN, FALSE);
-	g_snprintf(snd, MSG_LEN, "toc_set_config \"%s\"", buf);
-	sflap_send(gc, snd, -1, TYPE_DATA);
-}
-
 static void toc_close(struct gaim_connection *gc) {
-	toc_set_config(gc);
 	if (gc->inpa > 0)
 		gdk_input_remove(gc->inpa);
 	gc->inpa = -1;
@@ -761,6 +752,13 @@
 	sflap_send(gc, buf, -1, TYPE_DATA);
 }
 
+static void toc_set_config(struct gaim_connection *gc) {
+	char buf[MSG_LEN], snd[MSG_LEN];
+	toc_build_config(gc, buf, MSG_LEN, FALSE);
+	g_snprintf(snd, MSG_LEN, "toc_set_config \"%s\"", buf);
+	sflap_send(gc, snd, -1, TYPE_DATA);
+}
+
 static void toc_get_info(struct gaim_connection *g, char *name) {
 	char buf[MSG_LEN];
 	g_snprintf(buf, MSG_LEN, "toc_get_info %s", normalize(name));