Are you trying to avoid race conditions?
Don't you need 'volatile' and 'AtomicIncrement/AtomicDecrement'?