use poll() instead of select() when available