diff options
Diffstat (limited to 'shell/source/win32/shlxthandler/ooofilt/ooofilt.cxx')
-rw-r--r-- | shell/source/win32/shlxthandler/ooofilt/ooofilt.cxx | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/shell/source/win32/shlxthandler/ooofilt/ooofilt.cxx b/shell/source/win32/shlxthandler/ooofilt/ooofilt.cxx index ed49f8217a72..07bb501a0be8 100644 --- a/shell/source/win32/shlxthandler/ooofilt/ooofilt.cxx +++ b/shell/source/win32/shlxthandler/ooofilt/ooofilt.cxx @@ -908,10 +908,14 @@ extern "C" SCODE STDMETHODCALLTYPE DllGetClassObject( void ** ppvObj ) { + COooFilterCF* pImpl = 0; IUnknown *pResult = 0; if ( CLSID_COooFilter == cid ) - pResult = (IUnknown *) new COooFilterCF; + { + pImpl = new COooFilterCF; + pResult = (IUnknown *) pImpl; + } else return CLASS_E_CLASSNOTAVAILABLE; if ( 0 != pResult ) @@ -921,7 +925,7 @@ extern "C" SCODE STDMETHODCALLTYPE DllGetClassObject( pResult->Release(); else { - delete pResult; + delete pImpl; return E_UNEXPECTED; } } |