Check all classes and added synchronized modifier to all methods that
access shared memory.