summaryrefslogtreecommitdiff
path: root/res/res_hep.c
diff options
context:
space:
mode:
authorMatthew Jordan <mjordan@digium.com>2014-04-03 11:47:03 +0000
committerMatthew Jordan <mjordan@digium.com>2014-04-03 11:47:03 +0000
commitdb5bd60c2a66d67083179433739b30e49796d131 (patch)
tree99ea23eb98f59969dba3f8d5db047565dbecc28a /res/res_hep.c
parenteefcb79bfb4ce2bd0236fc4bb5d960a6df9f3cc4 (diff)
res_hep: Fix crash when hep.conf not available
Parts of res_hep properly checked for a valid configuration object before attempting to access the configuration. A check, however, was missed when a packet is sent. This patch fixes the crash caused by not checking if the configuration object is valid. ........ Merged revisions 411668 from http://svn.asterisk.org/svn/asterisk/branches/12 git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@411669 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'res/res_hep.c')
-rw-r--r--res/res_hep.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/res/res_hep.c b/res/res_hep.c
index 80863d332..474e15d6a 100644
--- a/res/res_hep.c
+++ b/res/res_hep.c
@@ -532,7 +532,7 @@ int hepv3_send_packet(struct hepv3_capture_info *capture_info)
RAII_VAR(struct module_config *, config, ao2_global_obj_ref(global_config), ao2_cleanup);
int res;
- if (!config->general->enabled) {
+ if (!config || !config->general->enabled) {
return 0;
}