Why doesn’t RevertToSelf undo the most recent SetThreadToken? | The Old New Thing
Posted by jpluimers on 2017/08/16
Oops: I fell in this trap as well: When you call SetThreadToken, [WayBack] it replaces the token. When you call RevertToSelf [WayBack], the token is cleared and the thread no longer has a token. Maybe RevertToSelf
should have been named ClearThreadToken
, since that would emphasize that the function erases any existing thread token, leaving the thread to inherit the identity of its host process.
Source: Why doesn’t RevertToSelf undo the most recent SetThreadToken? | The Old New Thing [WayBack]
–jeroen
Leave a Reply