[asterisk-commits] res sorcery realtime.c: Fix crash from NULL sorcery object t... (asterisk[master])
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Mon Nov 23 18:04:50 CST 2015
Mark Michelson has submitted this change and it was merged.
Change subject: res_sorcery_realtime.c: Fix crash from NULL sorcery object type.
......................................................................
res_sorcery_realtime.c: Fix crash from NULL sorcery object type.
If the sorcery object type is not found a NULL is returned.
Unfortunately, sorcery_realtime_filter_objectset() will crash after
complaining about not finding the object type and saying to expect errors.
* Use ao2_cleanup() instead of ao2_ref() to prevent the crash.
ASTERISK-25165
Reported by Corey Farrell
Change-Id: Ic3b64453ea3058cb68d5c26d97d4fe7b8eea2e97
---
M res/res_sorcery_realtime.c
1 file changed, 1 insertion(+), 1 deletion(-)
Approvals:
Mark Michelson: Looks good to me, approved
Anonymous Coward #1000019: Verified
Corey Farrell: Looks good to me, but someone else must approve
diff --git a/res/res_sorcery_realtime.c b/res/res_sorcery_realtime.c
index b2df298..8807c01 100644
--- a/res/res_sorcery_realtime.c
+++ b/res/res_sorcery_realtime.c
@@ -142,7 +142,7 @@
}
}
- ao2_ref(object_type, -1);
+ ao2_cleanup(object_type);
return objectset;
}
--
To view, visit https://gerrit.asterisk.org/1700
To unsubscribe, visit https://gerrit.asterisk.org/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ic3b64453ea3058cb68d5c26d97d4fe7b8eea2e97
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: master
Gerrit-Owner: Richard Mudgett <rmudgett at digium.com>
Gerrit-Reviewer: Anonymous Coward #1000019
Gerrit-Reviewer: Corey Farrell <git at cfware.com>
Gerrit-Reviewer: Mark Michelson <mmichelson at digium.com>
More information about the asterisk-commits
mailing list