mirror of
https://github.com/reactos/reactos.git
synced 2025-07-05 22:51:22 +00:00
fix reference counting output to tell us caller's file and line #
svn path=/trunk/; revision=17402
This commit is contained in:
parent
9ceeecd2bd
commit
ab9cdfc5dd
1 changed files with 8 additions and 6 deletions
|
@ -82,24 +82,26 @@ void* _alloca(size_t size);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(DBG) || defined(KDBG)
|
#if defined(DBG) || defined(KDBG)
|
||||||
static void CcRosCacheSegmentIncRefCount ( PCACHE_SEGMENT cs )
|
static void CcRosCacheSegmentIncRefCount_ ( PCACHE_SEGMENT cs, const char* file, int line )
|
||||||
{
|
{
|
||||||
++cs->ReferenceCount;
|
++cs->ReferenceCount;
|
||||||
if ( cs->Bcb->Trace )
|
if ( cs->Bcb->Trace )
|
||||||
{
|
{
|
||||||
DPRINT1("CacheSegment %p ++RefCount=%d, Dirty %d, PageOut %d\n",
|
DbgPrint("(%s:%i) CacheSegment %p ++RefCount=%d, Dirty %d, PageOut %d\n",
|
||||||
cs, cs->ReferenceCount, cs->Dirty, cs->PageOut );
|
file, line, cs, cs->ReferenceCount, cs->Dirty, cs->PageOut );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
static void CcRosCacheSegmentDecRefCount ( PCACHE_SEGMENT cs )
|
static void CcRosCacheSegmentDecRefCount_ ( PCACHE_SEGMENT cs, const char* file, int line )
|
||||||
{
|
{
|
||||||
--cs->ReferenceCount;
|
--cs->ReferenceCount;
|
||||||
if ( cs->Bcb->Trace )
|
if ( cs->Bcb->Trace )
|
||||||
{
|
{
|
||||||
DPRINT1("CacheSegment %p --RefCount=%d, Dirty %d, PageOut %d\n",
|
DbgPrint("(%s:%i) CacheSegment %p --RefCount=%d, Dirty %d, PageOut %d\n",
|
||||||
cs, cs->ReferenceCount, cs->Dirty, cs->PageOut );
|
file, line, cs, cs->ReferenceCount, cs->Dirty, cs->PageOut );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#define CcRosCacheSegmentIncRefCount(cs) CcRosCacheSegmentIncRefCount_(cs,__FILE__,__LINE__)
|
||||||
|
#define CcRosCacheSegmentDecRefCount(cs) CcRosCacheSegmentDecRefCount_(cs,__FILE__,__LINE__)
|
||||||
#else
|
#else
|
||||||
#define CcRosCacheSegmentIncRefCount(cs) (++((cs)->ReferenceCount))
|
#define CcRosCacheSegmentIncRefCount(cs) (++((cs)->ReferenceCount))
|
||||||
#define CcRosCacheSegmentDecRefCount(cs) (--((cs)->ReferenceCount))
|
#define CcRosCacheSegmentDecRefCount(cs) (--((cs)->ReferenceCount))
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue