Module: kamailio
Branch: master
Commit: 5d157208d6b145959b78fef76e6cc025c28e73cd
URL: 
https://github.com/kamailio/kamailio/commit/5d157208d6b145959b78fef76e6cc025c28e73cd

Author: Victor Seva <[email protected]>
Committer: Victor Seva <[email protected]>
Date: 2015-06-20T09:00:44+02:00

modules/db_text: clean gcc warning

dbt_raw_util.c: In function 'dbt_build_where':
dbt_raw_util.c:172:6: warning: unused variable 'n' [-Wunused-variable]
  int n, l;

---

Modified: modules/db_text/dbt_raw_util.c

---

Diff:  
https://github.com/kamailio/kamailio/commit/5d157208d6b145959b78fef76e6cc025c28e73cd.diff
Patch: 
https://github.com/kamailio/kamailio/commit/5d157208d6b145959b78fef76e6cc025c28e73cd.patch

---

diff --git a/modules/db_text/dbt_raw_util.c b/modules/db_text/dbt_raw_util.c
index 97012cc..ffbfa3b 100644
--- a/modules/db_text/dbt_raw_util.c
+++ b/modules/db_text/dbt_raw_util.c
@@ -169,7 +169,7 @@ int dbt_build_where(char* where, db_key_t** _k, db_op_t** 
_o, db_val_t** _v)
        char** _o1 = NULL;
        db_val_t* _v1 = NULL;
        regmatch_t* matches = NULL;
-       int n, l;
+       int l;
        int len;
        regex_t preg;
        int offset = 0;
@@ -239,11 +239,11 @@ int dbt_build_where(char* where, db_key_t** _k, db_op_t** 
_o, db_val_t** _v)
                        _v1[idx].val.str_val.s = pkg_malloc(l+1);
                        strncpy(_v1[idx].val.str_val.s, 
buffer+matches[5].rm_so, l);
                }
-
-//             for(n=0; n < MAX_MATCH; n++) {
-//                     LM_ERR("MATCH RESULT %d - %d,%d\n", n, 
matches[n].rm_so, matches[n].rm_eo);
-//             }
-
+/*
+               for(int n=0; n < MAX_MATCH; n++) {
+                       LM_ERR("MATCH RESULT %d - %d,%d\n", n, 
matches[n].rm_so, matches[n].rm_eo);
+               }
+*/
                if(matches[0].rm_eo != -1)
                        offset += matches[0].rm_eo;
 


_______________________________________________
sr-dev mailing list
[email protected]
http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-dev

Reply via email to