Fixed a synchronization bug.