Implemented poll() support for Process tasks.

Fixes #3035