removed unnecessary volatile keyword