Fixes #624 cleanup
This commit is contained in:
parent
59540f552c
commit
126e58c7cc
|
@ -380,14 +380,15 @@ public class HttpChannelState
|
|||
read_interested=_asyncReadUnready;
|
||||
_state=State.ASYNC_WAIT;
|
||||
action=Action.WAIT;
|
||||
scheduleTimeout();
|
||||
Scheduler scheduler = _channel.getScheduler();
|
||||
if (scheduler!=null && _timeoutMs>0)
|
||||
_event.setTimeoutTask(scheduler.schedule(_event,_timeoutMs,TimeUnit.MILLISECONDS));
|
||||
}
|
||||
break;
|
||||
|
||||
case EXPIRING:
|
||||
_state=State.ASYNC_WAIT;
|
||||
action=Action.WAIT;
|
||||
scheduleTimeout();
|
||||
break;
|
||||
|
||||
case ERRORING:
|
||||
|
@ -748,15 +749,6 @@ public class HttpChannelState
|
|||
_channel.execute(_channel);
|
||||
}
|
||||
|
||||
protected void scheduleTimeout()
|
||||
{
|
||||
if (!_locker.isLocked())
|
||||
throw new IllegalStateException();
|
||||
Scheduler scheduler = _channel.getScheduler();
|
||||
if (scheduler!=null && _timeoutMs>0)
|
||||
_event.setTimeoutTask(scheduler.schedule(_event,_timeoutMs,TimeUnit.MILLISECONDS));
|
||||
}
|
||||
|
||||
protected void cancelTimeout()
|
||||
{
|
||||
final AsyncContextEvent event;
|
||||
|
|
Loading…
Reference in New Issue