Question about synchronization method

You can get rid of spinlock if you put Flag1 and Flag2 into a single ULONG and read it with a single read.

Yes, thanks.

The iPhone did it!

:wink:

Peter
OSR

That looks totally legit to me.

Thereby either requiring you write a paragraph of documentation at each location that you do this, or risk incurring the confusion and ultimate wrath of every future maintainer of your code.

Just use the spin lock. That’s what they’re FOR, for goodness sakes!

Peter
OSR
@OSRDrivers