Hello,

I fixed the ones not in msg_translator.c, they were valid.

For msg_translator.c, I am not yet sure why they are thrown, recv_* vars are set for condition 'if (msg->rcv.bind_address)' and used only within that condition. What is your gcc version? I have 4.2 here and no warning there.

I can init them always, but it is better to understand first why the warning is given, not to fall in a trap with a default value.

Cheers,
Daniel

On 4/3/12 4:07 PM, Juha Heinanen wrote:
recently there has been commits that cause compiler warnings shown
below.

please fix or revert the commits.

-- juha

action.c: In function ‘run_actions’:
action.c:1583: warning: ‘ms’ may be used uninitialized in this function
CC (cc) [sip-proxy]             msg_translator.o
msg_translator.c: In function ‘lumps_len’:
msg_translator.c:582: warning: ‘recv_address_str’ may be used uninitialized in 
this function
msg_translator.c:583: warning: ‘recv_port_str’ may be used uninitialized in 
this function
msg_translator.c:584: warning: ‘recv_port_no’ may be used uninitialized in this 
function
msg_translator.c: In function ‘process_lumps’:
msg_translator.c:921: warning: ‘recv_address_str’ may be used uninitialized in 
this function
msg_translator.c:922: warning: ‘recv_port_str’ may be used uninitialized in 
this function
msg_translator.c:923: warning: ‘recv_port_no’ may be used uninitialized in this 
function
CC (cc) [L libsrdb1.so.1.0]             db_query.o
db_query.c: In function ‘db_do_submit_query’:
db_query.c:50: warning: ‘ms’ may be used uninitialized in this function
CC (cc) [M textops.so]          textops.o
textops.c: In function ‘subst_hf_f’:
textops.c:2242: warning: ‘hfl’ may be used uninitialized in this function
textops.c: In function ‘search_hf_f’:
textops.c:2161: warning: ‘hfl’ may be used uninitialized in this function

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

--
Daniel-Constantin Mierla
Kamailio Advanced Training, April 23-26, 2012, Berlin, Germany
http://www.asipto.com/index.php/kamailio-advanced-training/


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

Reply via email to