Now calls the new fs_shell only call kill_device_vnodes() in Volume::Initialize()
to be able to remove the cache correctly (without issuing any warnings). The Volume::Initialize() method is now only defined in USER mode (of course, this will change in OpenBeOS). git-svn-id: file:///srv/svn/repos/haiku/trunk/current@6481 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -531,6 +531,10 @@ Volume::RemoveQuery(Query *query)
|
||||
// Disk initialization
|
||||
|
||||
|
||||
#ifdef USER
|
||||
extern "C" void kill_device_vnodes(dev_t id);
|
||||
// This call is only available in the userland fs_shell
|
||||
|
||||
status_t
|
||||
Volume::Initialize(const char *device, const char *name, uint32 blockSize, uint32 flags)
|
||||
{
|
||||
@@ -626,12 +630,11 @@ Volume::Initialize(const char *device, const char *name, uint32 blockSize, uint3
|
||||
if (fIndicesNode != NULL)
|
||||
put_vnode(ID(), fIndicesNode->ID());
|
||||
|
||||
delete fIndicesNode;
|
||||
delete fRootNode;
|
||||
// ToDo: this is a temporary hack until new_vnode()/put_vnode() is working
|
||||
// correctly in the mkbfs command
|
||||
kill_device_vnodes(ID());
|
||||
// This call is only available in the userland fs_shell
|
||||
|
||||
Sync();
|
||||
opener.RemoveCache(ALLOW_WRITES);
|
||||
return B_OK;
|
||||
}
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user