[ros-dev] [ros-diffs] [gedmurphy] 69650: The c++ bool is 1 byte, not 4. Thanks Thomas
Thomas Faber
thomas.faber at reactos.org
Tue Nov 3 21:09:54 UTC 2015
On 2015-11-03 22:02, Timo Kreuzer wrote:
> m_RefreshPending is a 32 bit BOOL and the constructor will initialize it completely with 0.
> If it was initializing only the 1st byte, the new code would still be wrong, since it makes no difference.
> InterlockedCompareExchange will exchange 32 bit, no matter whether you pass a bool or a BOOL.
>>>> @@ -17,7 +17,7 @@
>>>> HMENU m_hMenu;
>>>> HMENU m_hActionMenu;
>>>> int m_CmdShow;
>>>> - bool m_RefreshPending;
>>>> + BOOL m_RefreshPending;
>>>>
>>>> public:
>>>> CDeviceManager(void);
Did you miss this part of the diff? ;)
More information about the Ros-dev
mailing list