thread-safe in distance computing fixed