]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
FS-3350 try this
authorJeff Lenk <jeff@jefflenk.com>
Thu, 16 Jun 2011 22:09:26 +0000 (17:09 -0500)
committerJeff Lenk <jeff@jefflenk.com>
Thu, 16 Jun 2011 22:09:26 +0000 (17:09 -0500)
src/mod/applications/mod_cidlookup/mod_cidlookup.c

index 64e5fc75203b52fff857f320e1ce264aec5431df..ba69f6fb6b7ae6086ac2a69222e31917e741cb57 100755 (executable)
@@ -554,6 +554,7 @@ static cid_data_t *do_lookup(switch_memory_pool_t *pool, switch_event_t *event,
        char *name = NULL;
        char *url_query = NULL;
        cid_data_t *cid = NULL;
+       cid_data_t *cidtmp = NULL;
        switch_bool_t save_cache = SWITCH_FALSE;
 
        cid = switch_core_alloc(pool, sizeof(cid_data_t));
@@ -573,8 +574,9 @@ static cid_data_t *do_lookup(switch_memory_pool_t *pool, switch_event_t *event,
        }
 
        if (globals.cache) {
-               cid = check_cache(pool, number);
-               if (cid) {
+               cidtmp = check_cache(pool, number);
+               if (cidtmp) {
+                       cid = cidtmp;
                        cid->src = switch_core_sprintf(pool, "%s (cache)", cid->src);
                        goto done;
                }