Fix corner cases in NettyApnsConnectionImpl