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:
syntheticpp 2005-12-17 13:15:30 +00:00
parent 327cf64701
commit 6a871fad44

View file

@ -178,7 +178,7 @@ namespace Loki
RefCountedMT()
{
pCount_ = static_cast<CountPtrType>(
SmallObject<ThreadingModel>::operator new(
SmallObject<LOKI_DEFAULT_THREADING_NO_OBJ_LEVEL>::operator new(
sizeof(*pCount_)));
assert(pCount_);
//*pCount_ = 1;
@ -205,7 +205,7 @@ namespace Loki
{
if (!ThreadingModel<RefCountedMT>::AtomicDecrement(*pCount_))
{
SmallObject<ThreadingModel>::operator delete(
SmallObject<LOKI_DEFAULT_THREADING_NO_OBJ_LEVEL>::operator delete(
const_cast<CountType *>(pCount_),
sizeof(*pCount_));
return true;