pjproject icon indicating copy to clipboard operation
pjproject copied to clipboard

Feature Request: ability to retrieve ioqueue fd/handle

Open mscdex opened this issue 3 years ago • 0 comments

Is your feature request related to a problem? Please describe. Currently there is no easy and efficient way to integrate pjsip's ioqueue into an existing polling mechanism (e.g. existing epoll instance that is already handling other file descriptors).

Describe the solution you'd like An API that returns a pj_oshandle_t containing the ioqueue's fd/handle. In the case of epoll, it would return the epfd. I'm not picky as to where the API lives, whether it's pjsip_endpt_get_ioqueue_handle(pjsip_endpoint *endpt), pj_ioqueue_get_handle(pj_ioqueue_t *ioque), and/or something else.

Describe alternatives you've considered Currently I have to copy a large chunk of struct definitions from the (epoll) ioqueue implementation (since those structures are not public) just so I can get at the epfd field. This is very unwieldy and not easily maintainable going forward.

mscdex avatar Jul 22 '22 21:07 mscdex