changed back volatile to non-volatile