equal
deleted
inserted
replaced
111 long to = timeout; |
111 long to = timeout; |
112 for (;;) { |
112 for (;;) { |
113 if (!ssc.isOpen()) |
113 if (!ssc.isOpen()) |
114 throw new ClosedChannelException(); |
114 throw new ClosedChannelException(); |
115 long st = System.currentTimeMillis(); |
115 long st = System.currentTimeMillis(); |
116 int result = ssc.poll(PollArrayWrapper.POLLIN, to); |
116 int result = ssc.poll(Net.POLLIN, to); |
117 if (result > 0 && ((sc = ssc.accept()) != null)) |
117 if (result > 0 && ((sc = ssc.accept()) != null)) |
118 return sc.socket(); |
118 return sc.socket(); |
119 to -= System.currentTimeMillis() - st; |
119 to -= System.currentTimeMillis() - st; |
120 if (to <= 0) |
120 if (to <= 0) |
121 throw new SocketTimeoutException(); |
121 throw new SocketTimeoutException(); |