Stream temp = httpResponse.GetResponseStream();
StreamReader stemp = new StreamReader(temp, System.Text.Encoding.GetEncoding("gb2312"));
string htmltemp = stemp.ReadToEnd();
单线程时没事,两个线程时,最后一句时出错说连接被意外关闭。 返回的是HttpStatusCode.OK,而且在执行最后一句前,temp都是CanRead的
StreamReader stemp = new StreamReader(temp, System.Text.Encoding.GetEncoding("gb2312"));
string htmltemp = stemp.ReadToEnd();
单线程时没事,两个线程时,最后一句时出错说连接被意外关闭。 返回的是HttpStatusCode.OK,而且在执行最后一句前,temp都是CanRead的
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货