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;
}