From 32e3f999727923b03369626590ad799718708619 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Revol?= Date: Sun, 25 Jan 2004 13:36:13 +0000 Subject: [PATCH] Debug Inode ctor/dctor; fix printf args warnigns git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6285 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/add-ons/kernel/file_systems/bfs/Inode.cpp | 13 +++++++++++-- src/add-ons/kernel/file_systems/bfs/Inode.h | 4 ++-- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/src/add-ons/kernel/file_systems/bfs/Inode.cpp b/src/add-ons/kernel/file_systems/bfs/Inode.cpp index 7908c89359..3e6796c66f 100644 --- a/src/add-ons/kernel/file_systems/bfs/Inode.cpp +++ b/src/add-ons/kernel/file_systems/bfs/Inode.cpp @@ -178,6 +178,9 @@ Inode::Inode(Volume *volume, vnode_id id, bool empty, uint8 reenter) fTree(NULL), fLock() { +#ifdef DEBUG + kprintf("Inode::Inode(0x%08lx, %Ld, %s, %s) @ 0x%08lx\n", (uint32)volume, id, empty?"t":"f", reenter?"t":"f", (uint32)this); +#endif Initialize(); } @@ -187,12 +190,18 @@ Inode::Inode(CachedBlock *cached) fTree(NULL), fLock() { +#ifdef DEBUG + kprintf("Inode::Inode(0x%08lx) @ 0x%08lx\n", (uint32)cached, (uint32)this); +#endif Initialize(); } Inode::~Inode() { +#ifdef DEBUG + kprintf("Inode::~Inode() @ 0x%08lx\n", (uint32)this); +#endif delete fTree; } @@ -2052,8 +2061,8 @@ Inode::KDumpMe() { kprintf("Inode {\n"); CachedBlock::KDumpMe(); - kprintf("fTree = 0x%08lx\n", fTree); - kprintf("fAttributes = 0x%08lx\n", fAttributes); + kprintf("fTree = 0x%08lx\n", (uint32)fTree); + kprintf("fAttributes = 0x%08lx\n", (uint32)fAttributes); kprintf("fLock {}\n"); kprintf("fOldSize = 0x%16Lx\n", fOldSize); kprintf("fOldLastModified = 0x%16Lx\n", fOldLastModified); diff --git a/src/add-ons/kernel/file_systems/bfs/Inode.h b/src/add-ons/kernel/file_systems/bfs/Inode.h index 2de7a96172..9ab034a897 100644 --- a/src/add-ons/kernel/file_systems/bfs/Inode.h +++ b/src/add-ons/kernel/file_systems/bfs/Inode.h @@ -383,9 +383,9 @@ inline void CachedBlock::KDumpMe() { kprintf("CachedBlock {\n"); - kprintf("fVolume = 0x%08lx\n", fVolume); + kprintf("fVolume = 0x%08lx\n", (uint32)fVolume); kprintf("fBlockNumber = 0x%16Lx\n", fBlockNumber); - kprintf("fBlock = 0x%08lx\n", fBlock); + kprintf("fBlock = 0x%08lx\n", (uint32)fBlock); kprintf("}\n"); }