[Elasticsearch] Forgot to swap condition variable's value.
[Elasticsearch] Forgot to swap condition variable's value.

Also event loop now accepts error code to check its correctness after stopping.

noxiouz/blackhole,3Hren/blackhole,antmat/blackhole,antmat/blackhole