Only setting flag as volatile