Parcourir la source

textopsx: init local variable to avoid testing invalid value

(cherry picked from commit f0186bf375d4653b5354df35a9a8d065b56522ee)
(cherry picked from commit df4991af5bc1458b7781cfd36b95940cbc1cc4de)
Daniel-Constantin Mierla il y a 11 ans
Parent
commit
435f9121d9
1 fichiers modifiés avec 2 ajouts et 1 suppressions
  1. 2 1
      modules/textopsx/textopsx.c

+ 2 - 1
modules/textopsx/textopsx.c

@@ -1195,7 +1195,8 @@ static int assign_hf_process2_params(struct sip_msg* msg, struct hdr_field* hf,
 static int insupddel_hf_value_f(struct sip_msg* msg, char* _hname, char* _val) {
 	struct hname_data* hname = (void*) _hname;
 	struct hdr_field* hf;
-	str val, hval1, hval2;
+	str val = {0};
+	str hval1, hval2;
 	int res;
 
 	if (_val) {