diff options
author | Caolán McNamara <caolanm@redhat.com> | 2011-11-18 08:56:49 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2011-11-19 21:11:01 +0000 |
commit | 705e5fe94769415cfca60c73eebb8232464645b2 (patch) | |
tree | 9934c6afc11c237b1bc4627d813925c8985940cd /comphelper | |
parent | fd094baaf79e391f99da9c8259b13144e8de7847 (diff) |
callcatcher: remove some unused code
Diffstat (limited to 'comphelper')
-rw-r--r-- | comphelper/inc/comphelper/oslfile2streamwrap.hxx | 2 | ||||
-rw-r--r-- | comphelper/source/streaming/oslfile2streamwrap.cxx | 27 |
2 files changed, 1 insertions, 28 deletions
diff --git a/comphelper/inc/comphelper/oslfile2streamwrap.hxx b/comphelper/inc/comphelper/oslfile2streamwrap.hxx index d62ca3db4108..e817be98d456 100644 --- a/comphelper/inc/comphelper/oslfile2streamwrap.hxx +++ b/comphelper/inc/comphelper/oslfile2streamwrap.hxx @@ -48,11 +48,9 @@ class COMPHELPER_DLLPUBLIC OSLInputStreamWrapper : public ::cppu::WeakImplHelper { ::osl::Mutex m_aMutex; ::osl::File* m_pFile; - sal_Bool m_bFileOwner : 1; public: OSLInputStreamWrapper(::osl::File& _rStream); - OSLInputStreamWrapper(::osl::File* pStream, sal_Bool bOwner=sal_False); virtual ~OSLInputStreamWrapper(); // stario::XInputStream diff --git a/comphelper/source/streaming/oslfile2streamwrap.cxx b/comphelper/source/streaming/oslfile2streamwrap.cxx index 68af33298336..81951b546c81 100644 --- a/comphelper/source/streaming/oslfile2streamwrap.cxx +++ b/comphelper/source/streaming/oslfile2streamwrap.cxx @@ -38,23 +38,13 @@ namespace comphelper //------------------------------------------------------------------ OSLInputStreamWrapper::OSLInputStreamWrapper( File& _rFile ) - :m_pFile(&_rFile) - ,m_bFileOwner(sal_False) -{ -} - -//------------------------------------------------------------------ -OSLInputStreamWrapper::OSLInputStreamWrapper( File* pStream, sal_Bool bOwner ) - :m_pFile( pStream ) - ,m_bFileOwner( bOwner ) + : m_pFile(&_rFile) { } //------------------------------------------------------------------ OSLInputStreamWrapper::~OSLInputStreamWrapper() { - if( m_bFileOwner ) - delete m_pFile; } //------------------------------------------------------------------------------ @@ -92,14 +82,6 @@ sal_Int32 SAL_CALL OSLInputStreamWrapper::readSomeBytes(staruno::Sequence< sal_I if (nMaxBytesToRead < 0) throw stario::BufferSizeExceededException(::rtl::OUString(),static_cast<staruno::XWeak*>(this)); - /* - if (m_pFile->IsEof()) - { - aData.realloc(0); - return 0; - } - else - */ return readBytes(aData, nMaxBytesToRead); } @@ -119,11 +101,6 @@ void SAL_CALL OSLInputStreamWrapper::skipBytes(sal_Int32 nBytesToSkip) throw( st { throw stario::NotConnectedException(::rtl::OUString(), static_cast<staruno::XWeak*>(this)); } - -#ifdef DBG_UTIL - m_pFile->getPos(nCurrentPos); -// volatile int dummy = 0; // to take a look at last changes ;-) -#endif } //------------------------------------------------------------------------------ @@ -163,8 +140,6 @@ void SAL_CALL OSLInputStreamWrapper::closeInput() throw( stario::NotConnectedExc throw stario::NotConnectedException(::rtl::OUString(), static_cast<staruno::XWeak*>(this)); m_pFile->close(); - if (m_bFileOwner) - delete m_pFile; m_pFile = NULL; } |