change to volatile variable