add some status protection
add more log
handle POLL_ERR first