Browse Source

XHR-pooling regression fixed (again). http://stackoverflow.com/questions/20051846

master
Nikita 12 years ago
parent
commit
bee684bc58
  1. 5
      src/main/java/com/corundumstudio/socketio/transport/XHRPollingClient.java

5
src/main/java/com/corundumstudio/socketio/transport/XHRPollingClient.java

@ -50,7 +50,8 @@ public class XHRPollingClient extends MainBaseClient {
}
public ChannelFuture send(final Packet packet) {
ChannelPromise promise = getChannel().newPromise();
Channel currChannel = getChannel();
ChannelPromise promise = currChannel.newPromise();
promise.addListener(new GenericFutureListener<Future<Void>>() {
@Override
public void operationComplete(Future<Void> future) throws Exception {
@ -62,7 +63,7 @@ public class XHRPollingClient extends MainBaseClient {
}
});
return getChannel().write(new XHRPacketMessage(getSessionId(), origin, packet), promise);
return currChannel.write(new XHRPacketMessage(getSessionId(), origin, packet), promise);
}
}
Loading…
Cancel
Save