fix up some event issues

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5541 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale committed 2007-07-24 21:26:04 +00:00
1 parent 46e564502a
commit 25057d40ac
3 files changed
+31 -15

No files matched your search

+4 -1
View File
@@ -455,7 +455,10 @@ SWITCH_DECLARE(switch_status_t) switch_event_create_subclass(switch_event_t **ev
(*event)->event_id = event_id;
if (subclass_name) {
(*event)->subclass = switch_core_hash_find(CUSTOM_HASH, subclass_name);
if (!((*event)->subclass = switch_core_hash_find(CUSTOM_HASH, subclass_name))) {
switch_event_reserve_subclass((char *)subclass_name);
(*event)->subclass = switch_core_hash_find(CUSTOM_HASH, subclass_name);
}
switch_event_add_header(*event, SWITCH_STACK_BOTTOM, "Event-Subclass", "%s", subclass_name);
}