backport changes from 1.4.3 branch

This commit is contained in:
Marian Krivos
2012-01-07 11:06:14 +00:00
parent cc90b38ae5
commit 6268aa3865
69 changed files with 10381 additions and 5761 deletions

View File

@@ -122,12 +122,12 @@ AtomicCounter& AtomicCounter::operator = (AtomicCounter::ValueType value)
}
#elif defined(POCO_ARCH_GCC_INTEL_X32_64)
#elif defined(POCO_HAVE_GCC_ATOMICS)
//
// GCC & Linux
// GCC 4.1+ atomic builtins.
//
AtomicCounter::AtomicCounter():
_counter(0)
_counter(0)
{
}
@@ -151,15 +151,15 @@ AtomicCounter::~AtomicCounter()
AtomicCounter& AtomicCounter::operator = (const AtomicCounter& counter)
{
_counter = counter.value();
return *this;
__sync_lock_test_and_set(&_counter, counter.value());
return *this;
}
AtomicCounter& AtomicCounter::operator = (AtomicCounter::ValueType value)
{
_counter = value;
return *this;
__sync_lock_test_and_set(&_counter, value);
return *this;
}