[Asterisk-code-review] pjsip distributor.c: Ignore messages until fully booted. (asterisk[13])
Richard Mudgett
asteriskteam at digium.com
Mon Jun 6 15:05:22 CDT 2016
Richard Mudgett has uploaded a new change for review.
https://gerrit.asterisk.org/2947
Change subject: pjsip_distributor.c: Ignore messages until fully booted.
......................................................................
pjsip_distributor.c: Ignore messages until fully booted.
We should not be processing any incoming messages until we are fully
booted. We may not have dialplan or other needed configuration loaded
yet.
ASTERISK-26088
Reported by: Richard Mudgett
Change-Id: I584aefb4f34b885a8927e1f13a2c64babd606264
---
M res/res_pjsip/pjsip_distributor.c
1 file changed, 10 insertions(+), 1 deletion(-)
git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/47/2947/1
diff --git a/res/res_pjsip/pjsip_distributor.c b/res/res_pjsip/pjsip_distributor.c
index 3867eae..288a3e0 100644
--- a/res/res_pjsip/pjsip_distributor.c
+++ b/res/res_pjsip/pjsip_distributor.c
@@ -290,11 +290,20 @@
static pj_bool_t distributor(pjsip_rx_data *rdata)
{
- pjsip_dialog *dlg = find_dialog(rdata);
+ pjsip_dialog *dlg;
struct distributor_dialog_data *dist = NULL;
struct ast_taskprocessor *serializer = NULL;
pjsip_rx_data *clone;
+ if (!ast_test_flag(&ast_options, AST_OPT_FLAG_FULLY_BOOTED)) {
+ /*
+ * Ignore everything until we are fully booted. Let the
+ * peer retransmit messages until we are ready.
+ */
+ return PJ_TRUE;
+ }
+
+ dlg = find_dialog(rdata);
if (dlg) {
ast_debug(3, "Searching for serializer on dialog %s for %s\n",
dlg->obj_name, pjsip_rx_data_get_info(rdata));
--
To view, visit https://gerrit.asterisk.org/2947
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: I584aefb4f34b885a8927e1f13a2c64babd606264
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
More information about the asterisk-code-review
mailing list