Browse code

lcr: compile & warning fixes for gcc 2.95

- variables must be declared at the beginning of a block

Andrei Pelinescu-Onciul authored on 12/10/2009 14:45:27
Showing 1 changed files
... ...
@@ -399,6 +399,7 @@ static int mod_init(void)
399 399
     str s;
400 400
     unsigned short avp_flags;
401 401
     unsigned int i;
402
+    db1_con_t* dbh;
402 403
 
403 404
 	if(register_mi_mod(exports.name, mi_cmds)!=0)
404 405
 	{
... ...
@@ -556,7 +557,6 @@ static int mod_init(void)
556 557
     }
557 558
 
558 559
     /* Check table version */
559
-    db1_con_t* dbh;
560 560
     if (lcr_dbf.init==0){
561 561
 	LM_CRIT("unbound database\n");
562 562
 	return -1;
... ...
@@ -1277,7 +1277,7 @@ int reload_gws_and_lcrs(int lcr_id)
1277 1277
 	    first_gw = find_first_gw(gw_grps, grp_cnt, grp_id);
1278 1278
 	    if (first_gw == 0) {
1279 1279
 		LM_ERR("gw grp_id <%u> of prefix <%.*s> has no gateways\n",
1280
-		       grp_id, prefix_len, prefix);
1280
+		       grp_id, (int)prefix_len, prefix);
1281 1281
 		goto lcr_err;
1282 1282
 	    }
1283 1283
 	    if ((VAL_NULL(ROW_VALUES(row) + 3) == 1) ||
... ...
@@ -1892,7 +1892,7 @@ static int generate_uris(char *r_uri, str *r_uri_user, unsigned int *r_uri_len,
1892 1892
     destroy_avp(gu_avp);
1893 1893
 	
1894 1894
     LM_DBG("r_uri <%.*s>, dst_uri <%.*s>\n",
1895
-	   *r_uri_len, r_uri, *dst_uri_len, dst_uri);
1895
+	   (int)*r_uri_len, r_uri, (int)*dst_uri_len, dst_uri);
1896 1896
 
1897 1897
     return 1;
1898 1898
 }