Closed
Bug 37146
Opened 25 years ago
Closed 25 years ago
The atomic.c test prints incorrect output
Categories
(NSPR :: NSPR, defect, P3)
Tracking
(Not tracked)
RESOLVED
FIXED
4.1
People
(Reporter: wtc, Assigned: wtc)
Details
The atomic.c test prints incorrect output.
It is supposed to print the old value of
the variable being atomically changed, but
it prints the new value.
The fix is to save the old value in 'oldval'
before each atomic operation and print 'oldval'.
Assignee | ||
Comment 1•25 years ago
|
||
I also fixed the checks in the test to verify
the new spec. of PR_AtomicIncrement/Decrement:
they return the result, not just the sign of
the result, of the increment/decrement operation.
The fix is checked in on the main trunk.
/cvsroot/mozilla/nsprpub/pr/tests/atomic.c, revision 3.5
Status: NEW → RESOLVED
Closed: 25 years ago
Resolution: --- → FIXED
Target Milestone: --- → 4.1
You need to log in
before you can comment on or make changes to this bug.
Description
•