libqutim: Make AsyncResult thread-safe