Changeset c05642d in mainline for uspace/lib/c/generic/async.c
- Timestamp:
- 2011-09-07T00:03:26Z (14 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- 5081276
- Parents:
- bb74dabe (diff), 038b289 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)
links above to see all the changes relative to each parent. - File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/c/generic/async.c
rbb74dabe rc05642d 1777 1777 int async_hangup(async_sess_t *sess) 1778 1778 { 1779 async_exch_t *exch; 1780 1779 1781 assert(sess); 1780 1782 1781 1783 if (atomic_get(&sess->refcnt) > 0) 1782 1784 return EBUSY; 1785 1786 fibril_mutex_lock(&async_sess_mutex); 1783 1787 1784 1788 int rc = async_hangup_internal(sess->phone); 1785 1789 if (rc == EOK) 1786 1790 free(sess); 1791 1792 while (!list_empty(&sess->exch_list)) { 1793 exch = (async_exch_t *) 1794 list_get_instance(list_first(&sess->exch_list), 1795 async_exch_t, sess_link); 1796 1797 list_remove(&exch->sess_link); 1798 list_remove(&exch->global_link); 1799 async_hangup_internal(exch->phone); 1800 free(exch); 1801 } 1802 1803 fibril_mutex_unlock(&async_sess_mutex); 1787 1804 1788 1805 return rc;
Note:
See TracChangeset
for help on using the changeset viewer.