Add libwebsocket_cancel_service() to let a pending libwebsocket_service() return

Use poll() with a pipe instead of ppoll() to allow the stop polling
on all UNIX platforms.