fix a bug of close the response stream.