Fix for thread race condition causes incorrect graph connectivity analysis