summaryrefslogtreecommitdiff
path: root/res
diff options
context:
space:
mode:
authorMatt Jordan <mjordan@digium.com>2015-10-25 10:12:03 -0500
committerGerrit Code Review <gerrit2@gerrit.digium.api>2015-10-25 10:12:03 -0500
commitd9be087da42fcee883edd7f314211848928286d0 (patch)
tree2c425cdc92ce51bce7757d2a73d139bbe214df70 /res
parent4d576fe6d9ece877ec8f65bbb224eb98bcf5fc0a (diff)
parent1bcc5927655c71f2ea0db31c0cd0a3bf0095714d (diff)
Merge "res_pjsip_pubsub: Fix crash on destruction of empty subscription tree." into 13
Diffstat (limited to 'res')
-rw-r--r--res/res_pjsip_pubsub.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/res/res_pjsip_pubsub.c b/res/res_pjsip_pubsub.c
index dc6178650..75b286b61 100644
--- a/res/res_pjsip_pubsub.c
+++ b/res/res_pjsip_pubsub.c
@@ -1079,6 +1079,10 @@ static void destroy_subscriptions(struct ast_sip_subscription *root)
{
int i;
+ if (!root) {
+ return;
+ }
+
for (i = 0; i < AST_VECTOR_SIZE(&root->children); ++i) {
struct ast_sip_subscription *child;