Re: [PATCH] Fix aliases in smsbox v2
Vincent CHAVANIS wrote: Here is a new version in my devel cvs tree, a bit more verbose in debug -logs for aliases and services names -logs when executing get_matching_translations() and return an empty list commited to cvs, but without he last debug() line, since this is an add-on... 2006-10-13 Stipe Tolj stolj at kannel.org * gw/urltran.c: fxing alias support for sms-service in smsbox. Thanks to Vincent for analysis and patch. Also removed debugging grp_dump() from Alex' previous UTF-8 patch. [Msg-Id: [EMAIL PROTECTED]] --- Kölner Landstrasse 419 40589 Düsseldorf, NRW, Germany tolj.org system architecture Kannel Software Foundation (KSF) http://www.tolj.org/ http://www.kannel.org/ mailto:st_{at}_tolj.org mailto:stolj_{at}_kannel.org ---
Re: [PATCH] Fix aliases in smsbox
Vincent CHAVANIS wrote: It fixes aliases in smsbox. I don't understand why list should be destroy after executing the function find_translation() It fixes the segfault when smsbox is exiting. (seem happens in free variables process) Thanks uhuru for reporting this and provide a patch. Please comment/vote anyone reviewed this one from Vincent? Stipe --- Kölner Landstrasse 419 40589 Düsseldorf, NRW, Germany tolj.org system architecture Kannel Software Foundation (KSF) http://www.tolj.org/ http://www.kannel.org/ mailto:st_{at}_tolj.org mailto:stolj_{at}_kannel.org ---
Re: [PATCH] Fix aliases in smsbox
Hi, this patch works fine ;p Thanks Vincent!!! vote 1++ for cvs. -- Humberto Figuera - Using Linux 2.6.17 Usuario GNU/Linux 369709 Caracas - Venezuela GPG Key Fingerprint = 5AAC DF0C 00F4 2834 28BA 37AD 3364 01D1 74CA 0603
[PATCH] Fix aliases in smsbox
It fixes aliases in smsbox. I don't understand why list should be destroy after executing the function find_translation() It fixes the segfault when smsbox is exiting. (seem happens in free variables process) Thanks uhuru for reporting this and provide a patch. Please comment/vote regards Vincent. -- Telemaque - 06200 NICE - (FR) Service Technique/Reseau - NOC Developpement SMS/MMS/Kiosques http://www.telemaque.fr/ [EMAIL PROTECTED] Tel : +33 4 93 97 71 64 (fax 68) diff -rau /gateway-cvs/gw/urltrans.c /gateway/gw/urltrans.c --- /gateway-cvs/gw/urltrans.c 2006-04-24 23:42:56.0 +0200 +++ /gateway/gw/urltrans.c 2006-09-28 16:48:39.0 +0200 @@ -1381,6 +1381,13 @@ octstr_convert_range(keyword, 0, octstr_len(keyword), tolower); list = get_matching_translations(trans, keyword); + +/* + if list is empty we will check into trans-dict (Dict of lowercase Octstr keywords) +*/ +if (gwlist_len(list) == 0) +list = dict_get(trans-dict, keyword); + /* list now contains all translations where the keyword of the sms matches the pattern defined by the tranlsation's keyword @@ -1401,7 +1408,6 @@ *reject = 0; octstr_destroy(keyword); -gwlist_destroy(list, NULL); return t; }