diff --git a/mbuni/mmsbox/mmsbox_cfg.c b/mbuni/mmsbox/mmsbox_cfg.c index f9a08fb..ac861e2 100644 --- a/mbuni/mmsbox/mmsbox_cfg.c +++ b/mbuni/mmsbox/mmsbox_cfg.c @@ -836,10 +836,10 @@ Octstr *get_mmsbox_queue_dir(Octstr *from, List *to, MmscGrp *m, Octstr **mmc_id) { - if (m->reroute) { + if (m && m->reroute) { *mmc_id = m->reroute_mmsc_id ? octstr_duplicate(m->reroute_mmsc_id) : NULL; return outgoing_qdir; - } else { + } else if (m) { Octstr *_mcid, *qdir = NULL; Octstr *fto;