Changeset 3899 for pjproject/trunk/pjmedia/src/pjmedia/event.c
- Timestamp:
- Dec 7, 2011 4:19:28 AM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
pjproject/trunk/pjmedia/src/pjmedia/event.c
r3893 r3899 88 88 static pj_status_t event_mgr_distribute_events(pjmedia_event_mgr *mgr, 89 89 event_queue *ev_queue, 90 esub **next_sub) 90 esub **next_sub, 91 pj_bool_t rls_lock) 91 92 { 92 93 pj_status_t err = PJ_SUCCESS; … … 101 102 */ 102 103 if (sub->epub == ev->epub || !sub->epub) { 103 pj_status_t status = (*sub->cb)(ev, sub->user_data); 104 pjmedia_event_cb *cb = sub->cb; 105 void *user_data = sub->user_data; 106 pj_status_t status; 107 108 if (rls_lock) 109 pj_mutex_unlock(mgr->mutex); 110 111 status = (*cb)(ev, user_data); 104 112 if (status != PJ_SUCCESS && err == PJ_SUCCESS) 105 113 err = status; 114 115 if (rls_lock) 116 pj_mutex_lock(mgr->mutex); 106 117 } 107 118 sub = *next_sub; … … 128 139 129 140 pj_mutex_lock(mgr->mutex); 130 event_mgr_distribute_events(mgr, &mgr->ev_queue, &mgr->th_next_sub); 141 event_mgr_distribute_events(mgr, &mgr->ev_queue, 142 &mgr->th_next_sub, PJ_TRUE); 131 143 pj_mutex_unlock(mgr->mutex); 132 144 } … … 347 359 do { 348 360 status = event_mgr_distribute_events(mgr, mgr->pub_ev_queue, 349 &mgr->pub_next_sub); 361 &mgr->pub_next_sub, 362 PJ_FALSE); 350 363 if (status != PJ_SUCCESS && err == PJ_SUCCESS) 351 364 err = status;
Note: See TracChangeset
for help on using the changeset viewer.