Message ID | 4D6E4E62.7030008@unine.ch |
---|---|
State | New |
Headers | show |
On 03/03/2011 12:04 AM, Patrick Marlier wrote:
> * config/posix/rwlock.cc (write_upgrade): Add missing case.
Applied.
r~
Index: libitm/config/posix/rwlock.cc =================================================================== --- libitm/config/posix/rwlock.cc (revision 170587) +++ libitm/config/posix/rwlock.cc (working copy) @@ -130,6 +130,11 @@ // We only return from upgrade when we've got it; don't loop. assert ((sum & (a_reader | a_writer)) == 0); } + else + { + // We were the only reader. + sum &= ~a_reader; + } // Otherwise we can upgrade to writer. this->summary = sum | a_writer;