set pipe writing end nonblock to skip a bug