@toharish commented on this pull request.
@@ -2649,13 +2672,18 @@ static bencode_item_t
*rtpp_function_call(bencode_buffer_t *bencbuf, struct sip_
bencode_dictionary_add_str(ng_flags.dict, "via-branch", &viabranch);
}
- item = bencode_list(bencbuf);
- bencode_dictionary_add(ng_flags.dict, "received-from", item);
- bencode_list_add_string(item, (msg->rcv.src_ip.af == AF_INET) ? "IP4" : (
- (msg->rcv.src_ip.af == AF_INET6) ? "IP6" :
- "?"
- ) );
- bencode_list_add_string(item, ip_addr2a(&msg->rcv.src_ip));
+ if (ng_flags.received_from && ng_flags.received_from->child) {
+ bencode_dictionary_add(ng_flags.dict, "received-from",
ng_flags.received_from);
+ }
+ else {
+ item = bencode_list(bencbuf);
Reuse of ng_flags.received_from done
fixed ng_flags.received-from = bencode_list(bencbuf); to ng_flags.received_from =
bencode_list(bencbuf);
complied and verified. Thank you for your support.
--
Reply to this email directly or view it on GitHub:
https://github.com/kamailio/kamailio/pull/3230#discussion_r965141171
You are receiving this because you are subscribed to this thread.
Message ID: <kamailio/kamailio/pull/3230/review/1099609992(a)github.com>