Ensure poller ends when requested

Using volatile makes sure the compiler won't optimize us into an
infinite loop. There may be implementation details in this case that
prevent this optimization from happening in practice, but it's probably
safer and clearer to just use volatile.

See http://docs.oracle.com/javase/specs/jls/se7/html/jls-17.html#jls-17.3