Re: Some remarks

"Vincent CHAVANIS" <[email protected]>
Newsgroups gmane.comp.mobile.kannel.devel
Message-ID <13f901c6a102$d4734b10$9600a8c0@vince>
Yep, i'm in favor of normlizing all args. (host=-h port=-p etc...)

btw, your patch is incomplete, (i.e static char usage)

regards

Vincent. 

--
Telemaque - NICE - (FR)
Service Technique - Developpement
http://www.telemaque.fr/
[email protected]
Tel : +33 4 93 97 71 64 (fax 68)

----- Original Message ----- > Colin Pitrat wrote:
>> Hello,
>> as I tested kannel, I found a few things :
>> 
>>   - in test/fakesmsc.c, the short option for port should be "-p" but in 
>> the code it is defined as "-r". Here is the modification I made :
>> 
>> -------------------------------------------------------------------------
>> diff -ru gateway-1.4.0/test/fakesmsc.c gateway-1.4.0-new/test/fakesmsc.c
>> --- gateway-1.4.0/test/fakesmsc.c       2004-10-28 18:32:14.000000000 +0200
>> +++ gateway-1.4.0-new/test/fakesmsc.c   2006-06-30 15:26:50.000000000 +0200
>> @@ -161,7 +161,7 @@
>>   /* our arguments */
>>   static int check_args(int i, int argc, char **argv)
>>   {
>> -    if (strcmp(argv[i], "-r")==0 || strcmp(argv[i], "--port")==0)
>> +    if (strcmp(argv[i], "-p")==0 || strcmp(argv[i], "--port")==0)
>>           port = atoi(argv[i+1]);
>>       else if (!strcmp(argv[i], "-H") || !strcmp(argv[i], "--host"))
>>           host = octstr_create(argv[i+1]);
>> -------------------------------------------------------------------------
>> 
>>   - On sending an empty MWI sms (without udh), a default "empty message" 
>> message is added. Judging by the fields_to_dcs function in sms.c, the 
>> message should remain empty. Here is the modifications I made :
>> 
>> -------------------------------------------------------------------------
>> --- gateway-1.4.0/gw/smsbox.c   2006-06-26 17:35:50.000000000 +0200
>> +++ gateway-1.4.0-new/gw/smsbox.c       2006-06-27 16:40:09.000000000 +0200
>> @@ -257,12 +257,9 @@
>>        *  a) it's a HTTP sms-service reply: either ignore it or
>>        *     substitute the "empty" warning defined
>>        *  b) it's a sendsms HTTP interface call: leave the message empty
>> -     *     if at least a UDH is given.
>> -     *
>> -     * XXX this still does not cover the case when the sendsms interface is
>> -     * used with *no* text and udh. What should we do then?!
>>        */
>> -    if (octstr_len(msg->sms.msgdata) == 0 && 
>> octstr_len(msg->sms.udhdata) == 0) {
>> +    if (octstr_len(msg->sms.msgdata) == 0 && msg->sms.sms_type == 
>> mt_reply) {
>> +    //if (octstr_len(msg->sms.msgdata) == 0 && 
>> octstr_len(msg->sms.udhdata) == 0) {
>>           if (trans != NULL && urltrans_omit_empty(trans))
>>               return 0;
>>           else
>> -------------------------------------------------------------------------
>>
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.