src/irc_conn.c
changeset 32 ae66e9ae4afb
parent 29 3f0f2898fea3
child 33 e5139b339b18
--- a/src/irc_conn.c	Tue Mar 10 03:29:53 2009 +0200
+++ b/src/irc_conn.c	Tue Mar 10 03:38:20 2009 +0200
@@ -80,6 +80,10 @@
     }
 }
 
+static struct line_proto_callbacks _lp_callbacks = {
+    .on_line        = &irc_conn_on_line,
+};
+
 err_t irc_conn_create (struct irc_conn **conn_ptr, struct sock_stream *sock, const struct irc_conn_callbacks *callbacks, 
         void *cb_arg, struct error_info *err)
 {
@@ -101,7 +105,7 @@
         goto error;
 
     // create the line_proto, with our on_line handler
-    if (line_proto_create(&conn->lp, sock, IRC_LINE_MAX * 1.5, &irc_conn_on_line, conn, err))
+    if (line_proto_create(&conn->lp, sock, IRC_LINE_MAX * 1.5, &_lp_callbacks, conn, err))
         goto error;
 
     // ok