Fixed a stream bug when stopping and restarting streaming.