Re: Foxgui-users Digest, Vol 179, Issue 1
Jeroen van der Zijp <[email protected]>
| Newsgroups | gmane.comp.lib.fox-toolkit.user |
|---|---|
| Organization | FOX Toolkit |
| Message-ID | <20221011203134.4761fb1b@leviathan> |
On Tue, 11 Oct 2022 22:18:20 +0200 Pof <[email protected]> wrote: >Dear Jeroen, > >thanks for this new release. > >I am updating from 1.7.74 on Visual C++ 2015, using 64 bits version. > >Only 2 compilation errors in FXAtomic (I already had this issue trying >to move from 1.7.74 to 1.7.77, then I stayed to 1.7.74) in: >#1) in line 268 (commented below) >// return _InterlockedAdd64(ptr,v); >corrected as > _InterlockedExchangeAdd64(ptr,v); > return *ptr; This may compile, but is not correct: 1) should return value prior to the addition; not new value after addition. 2) operation could be interrupted by another thread. >#2) in line 427 (commented below) >// return _InterlockedAdd64(reinterpret_cast<volatile FXlong*>(ptr),v); >corrected as > _InterlockedExchangeAdd64(reinterpret_cast<volatile FXlong*>(ptr),v); > return *ptr; Same of course applies here. Problems have been fixed and new snapshot will be dropped presently. -- JVZ -- +----------------------------------------------------------------------------+ | Copyright (C) 20:10 10/11/2022 Jeroen van der Zijp. All Rights Reserved. | +----------------------------------------------------------------------------+ _______________________________________________ Foxgui-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/foxgui-users