[PATCH] bb_smscconn.c

Nisan Bloch <[email protected]>
Newsgroups gmane.comp.mobile.kannel.devel
Message-ID <[email protected]>
Hi

A patch for bb_smscconn.c

bb_smscconn.c:sms_router calls bb_smscconn_send_failed with a NULL value 
for conn
       bb_smscconn_send_failed(NULL, msg, ................

bb_smscconn_send_failed does not check for this and tries to use conn.

Nisan
bb_smscconn.patch (text/plain, 611 B)
--- ../cvs/gateway/gw/bb_smscconn.ccvs/gWed Feb 11 07:40:13 2004gw/bb_smscconn.c
+++ gw/bb_smscconn.c    Fri Mar  5 00:15:07 2004
@@ -212,7 +212,8 @@
        (void) store_save(mnack);
        msg_destroy(mnack);

-       if (conn) counter_increase(conn->failed);
+               if (conn) {
+                       counter_increase(conn->failed);
        if (reason == SMSCCONN_FAILED_DISCARDED)
            bb_alog_sms(conn, sms, "DISCARDED SMS");
        else
@@ -233,6 +234,7 @@
                 bb_smscconn_receive(conn, dlrmsg);
             }
         }
+               }
        msg_destroy(sms);
     }
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.