Fix segfault.
authorJelmer Vernooij <jelmer@samba.org>
Mon, 25 Aug 2008 16:39:17 +0000 (18:39 +0200)
committerJelmer Vernooij <jelmer@samba.org>
Mon, 25 Aug 2008 16:39:17 +0000 (18:39 +0200)
lib/connection.c

index b50d8708893fa09f4c4efc1aa4220145586d2e51..5bcdc564997a1e58740d7c3aeeb94b9532a8240b 100644 (file)
@@ -195,8 +195,11 @@ static gboolean network_send_line_direct(struct irc_network *s, struct irc_clien
                if (s->connection.data.virtual.ops == NULL) 
                        return FALSE;
                return s->connection.data.virtual.ops->to_server(s, c, l);
-       } else 
+       } else {
+               if (s->connection.transport == NULL)
+                       return FALSE;
                return transport_send_line(s->connection.transport, l);
+       }
 }
 
 /**