make object level locking possible
git-svn-id: svn://svn.code.sf.net/p/loki-lib/code/trunk@382 7ec92016-0320-0410-acc4-a06ded1c099a
This commit is contained in:
parent
327cf64701
commit
6a871fad44
1 changed files with 2 additions and 2 deletions
|
@ -178,7 +178,7 @@ namespace Loki
|
||||||
RefCountedMT()
|
RefCountedMT()
|
||||||
{
|
{
|
||||||
pCount_ = static_cast<CountPtrType>(
|
pCount_ = static_cast<CountPtrType>(
|
||||||
SmallObject<ThreadingModel>::operator new(
|
SmallObject<LOKI_DEFAULT_THREADING_NO_OBJ_LEVEL>::operator new(
|
||||||
sizeof(*pCount_)));
|
sizeof(*pCount_)));
|
||||||
assert(pCount_);
|
assert(pCount_);
|
||||||
//*pCount_ = 1;
|
//*pCount_ = 1;
|
||||||
|
@ -205,7 +205,7 @@ namespace Loki
|
||||||
{
|
{
|
||||||
if (!ThreadingModel<RefCountedMT>::AtomicDecrement(*pCount_))
|
if (!ThreadingModel<RefCountedMT>::AtomicDecrement(*pCount_))
|
||||||
{
|
{
|
||||||
SmallObject<ThreadingModel>::operator delete(
|
SmallObject<LOKI_DEFAULT_THREADING_NO_OBJ_LEVEL>::operator delete(
|
||||||
const_cast<CountType *>(pCount_),
|
const_cast<CountType *>(pCount_),
|
||||||
sizeof(*pCount_));
|
sizeof(*pCount_));
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue