考考你,一个很简单却很多人都不确定的问题
摘要:
A:void Test(int i){ while(i>0) { lock(this) { i--; Test(i); } }}会死锁不?或者,B:void Test(int i){ while(i>0) { lock(this) { i--; System.Threading.Thread thread = new System.Threading.Thread(new System.Threading.ParameterizedThreadStart(delegate(object obj) {int ii=(int)obj; Tes... 阅读全文
posted @ 2011-09-26 19:22 狼行虹雨 阅读(2088) 评论(12) 推荐(1)
浙公网安备 33010602011771号