From 3d3166e17879522893f82b7bb04719e66c8d1ceb Mon Sep 17 00:00:00 2001 From: Vincent Povirk Date: Mon, 30 Nov 2009 17:22:58 -0600 Subject: [PATCH 5/5] ole32: Remove the ancestorStorage attribute. --- dlls/ole32/storage32.c | 15 +-------------- dlls/ole32/storage32.h | 5 ----- 2 files changed, 1 insertions(+), 19 deletions(-) diff --git a/dlls/ole32/storage32.c b/dlls/ole32/storage32.c index 2812555..eaddcbf 100644 --- a/dlls/ole32/storage32.c +++ b/dlls/ole32/storage32.c @@ -2459,12 +2459,6 @@ static HRESULT StorageImpl_Construct( This->base.ref = 1; This->base.create = create; - /* - * This is the top-level storage so initialize the ancestor pointer - * to this. - */ - This->base.ancestorStorage = This; - This->base.reverted = 0; This->hFile = hFile; @@ -3822,12 +3816,10 @@ SmallBlockChainStream* Storage32Impl_BigBlocksToSmallBlocks( static void StorageInternalImpl_Invalidate( StorageInternalImpl *This ) { - if (This->base.ancestorStorage) + if (!This->base.reverted) { TRACE("Storage invalidated (stg=%p)\n", This); - This->base.ancestorStorage = NULL; - This->base.reverted = 1; This->parentStorage = NULL; @@ -4388,11 +4380,6 @@ static StorageInternalImpl* StorageInternalImpl_Construct( newStorage->base.baseVtbl = &StorageInternalImpl_BaseVtbl; newStorage->base.openFlags = (openFlags & ~STGM_CREATE); - /* - * Keep the ancestor storage pointer but do not nail a reference to it. - */ - newStorage->base.ancestorStorage = parentStorage->ancestorStorage; - newStorage->base.reverted = 0; newStorage->parentStorage = parentStorage; diff --git a/dlls/ole32/storage32.h b/dlls/ole32/storage32.h index ff526bf..c68c6ea 100644 --- a/dlls/ole32/storage32.h +++ b/dlls/ole32/storage32.h @@ -214,11 +214,6 @@ struct StorageBaseImpl LONG ref; /* - * Ancestor storage (top level) - */ - StorageImpl* ancestorStorage; - - /* * TRUE if this object has been invalidated */ int reverted; -- 1.6.3.3