Pārlūkot izejas kodu

pua_dialoginfo: proper jump to end of the structure

- void has no standard size
- descovered on a report by Charles Chance

(cherry picked from commit 4108c7a125a3e50d1d670bc4c842b29cc32ec438)
(cherry picked from commit e65b32a7fef536638babe848d8b796fc26929bf7)
Daniel-Constantin Mierla 11 gadi atpakaļ
vecāks
revīzija
457fdfbc1b
1 mainītis faili ar 1 papildinājumiem un 1 dzēšanām
  1. 1 1
      modules/pua_dialoginfo/pua_dialoginfo.c

+ 1 - 1
modules/pua_dialoginfo/pua_dialoginfo.c

@@ -347,7 +347,7 @@ struct str_list*  get_str_list(unsigned short avp_flags, int_str avp_name) {
 
 		memset( list_current, 0, len);
 
-		list_current->s.s = (char*)( (void*) list_current + sizeof(struct str_list));
+		list_current->s.s = (char*)list_current + sizeof(struct str_list);
 		list_current->s.len = avp_value.s.len;
 		memcpy(list_current->s.s,avp_value.s.s,avp_value.s.len);