diff options
author | Nanang Izzuddin <nanang@teluu.com> | 2017-01-23 04:32:34 +0000 |
---|---|---|
committer | Nanang Izzuddin <nanang@teluu.com> | 2017-01-23 04:32:34 +0000 |
commit | f6d78bf855f2d564f9e383508908631a4668e2af (patch) | |
tree | 223bd69531113c5069679f9a6d482c03863284c9 /pjlib/src/pj/ioqueue_select.c | |
parent | dfe36134873cb77d5b9c2a999f3134eb79f6ca6e (diff) |
Re #1900: Reintegrated works in UWP branch to trunk.
git-svn-id: http://svn.pjsip.org/repos/pjproject/trunk@5539 74dad513-b988-da41-8d7b-12977e46ad98
Diffstat (limited to 'pjlib/src/pj/ioqueue_select.c')
-rw-r--r-- | pjlib/src/pj/ioqueue_select.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/pjlib/src/pj/ioqueue_select.c b/pjlib/src/pj/ioqueue_select.c index 8dd01720..438b37a2 100644 --- a/pjlib/src/pj/ioqueue_select.c +++ b/pjlib/src/pj/ioqueue_select.c @@ -894,8 +894,21 @@ PJ_DEF(int) pj_ioqueue_poll( pj_ioqueue_t *ioqueue, const pj_time_val *timeout) /* Unlock ioqueue before select(). */ pj_lock_release(ioqueue->lock); +#if defined(PJ_WIN32_WINPHONE8) && PJ_WIN32_WINPHONE8 + count = 0; + __try { +#endif + count = pj_sock_select(nfds+1, &rfdset, &wfdset, &xfdset, timeout); + +#if defined(PJ_WIN32_WINPHONE8) && PJ_WIN32_WINPHONE8 + /* Ignore Invalid Handle Exception raised by select().*/ + } + __except (GetExceptionCode() == STATUS_INVALID_HANDLE ? + EXCEPTION_CONTINUE_EXECUTION : EXCEPTION_CONTINUE_SEARCH) { + } +#endif if (count == 0) return 0; |