فهرست منبع

corez: set sndinfo attributes for corex_sip_reply_out()

(cherry picked from commit b003a7184a02da5fd6dfe27def8d928d363e36ce)
Daniel-Constantin Mierla 9 ماه پیش
والد
کامیت
b512a9e809
1فایلهای تغییر یافته به همراه10 افزوده شده و 0 حذف شده
  1. 10 0
      src/modules/corex/corex_mod.c

+ 10 - 0
src/modules/corex/corex_mod.c

@@ -1274,6 +1274,16 @@ static int corex_sip_reply_out(sr_event_param_t *evp)
 	str evname = str_init("corex:reply-out");
 
 	memset(&sndinfo, 0, sizeof(onsend_info_t));
+	sndinfo.dst = evp->dst;
+	if(evp->rpl != NULL) {
+		sndinfo.msg = evp->rpl;
+		sndinfo.buf = evp->rpl->buf;
+		sndinfo.len = evp->rpl->len;
+	} else {
+		sndinfo.msg = evp->req;
+		sndinfo.buf = evp->req->buf;
+		sndinfo.len = evp->req->len;
+	}
 
 	if(corex_evrt_reply_out_no >= 0 || corex_evcb_reply_out.len > 0) {
 		run_onsend_evroute(&sndinfo, corex_evrt_reply_out_no,