Go Back   ZeroC Forums > Bug Reports

Reply
 
LinkBack Thread Tools Rate Thread Display Modes
  #1 (permalink)  
Old 01-26-2004
vukicevic vukicevic is offline
Registered User
 
 
Join Date: May 2003
Location: San Francisco
Posts: 34
ice_atomic_exchange_add

In IceUtil/Shared.h, the comments for ice_atomic_exchange_add at line 118 (1.2.0 release) indicate that it behaves the same as the windows InterlockedExchangeAdd function. However, the function returns tmp+i, i.e. the value of the atomic variable after the add. InterlockedExchangeAdd returns the value of the variable before the add (just tmp, in this case).

This probably isn't noticable, since the only place exchange_add seems to be used is to exchange_add(0, &t), but I'm not sure if it's a documentation bug or a small code bug.
__________________
vladimir@pobox.com
Reply With Quote
Reply



Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


All times are GMT -4. The time now is 12:49 PM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.0.0
(c) 2008 ZeroC, Inc.