xmlsecurity/source/gpg/CipherContext.cxx | 8 ++++---- xmlsecurity/source/gpg/DigestContext.cxx | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-)
New commits: commit 3ecca2522d768bb66fa0ad8d8d64cb33cc3ea99f Author: Caolán McNamara <caol...@redhat.com> Date: Tue Mar 7 09:05:20 2017 +0000 coverity#1402074 Resource leak and coverity#1402075 Resource leak coverity#1402076 Resource leak Change-Id: I41f2ad480a43e3563b08a6316d4e74bfe8efd378 diff --git a/xmlsecurity/source/gpg/CipherContext.cxx b/xmlsecurity/source/gpg/CipherContext.cxx index 97d27dc..a38dbe0 100644 --- a/xmlsecurity/source/gpg/CipherContext.cxx +++ b/xmlsecurity/source/gpg/CipherContext.cxx @@ -16,15 +16,15 @@ using namespace css::lang; Sequence< sal_Int8 > SAL_CALL CipherContext::convertWithCipherContext( const Sequence< sal_Int8 >& /*aData*/ ) throw ( IllegalArgumentException, DisposedException, RuntimeException, std::exception) { - Sequence<sal_Int8>* seq = new Sequence< sal_Int8 >(0); - return *seq; + Sequence<sal_Int8> seq(0); + return seq; } uno::Sequence< sal_Int8 > SAL_CALL CipherContext::finalizeCipherContextAndDispose() throw (DisposedException, RuntimeException, std::exception) { - Sequence<sal_Int8>* seq = new Sequence< sal_Int8 >(0); - return *seq; + Sequence<sal_Int8> seq(0); + return seq; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/xmlsecurity/source/gpg/DigestContext.cxx b/xmlsecurity/source/gpg/DigestContext.cxx index 5d86b7c..fecc5f8 100644 --- a/xmlsecurity/source/gpg/DigestContext.cxx +++ b/xmlsecurity/source/gpg/DigestContext.cxx @@ -23,8 +23,8 @@ void SAL_CALL DigestContext::updateDigest( const uno::Sequence< ::sal_Int8 >& /* uno::Sequence< sal_Int8 > SAL_CALL DigestContext::finalizeDigestAndDispose() throw (DisposedException, RuntimeException, std::exception) { - Sequence<sal_Int8>* seq = new Sequence< sal_Int8 >(0); - return *seq; + Sequence<sal_Int8> seq(0); + return seq; } /* vim:set shiftwidth=4 softtabstop=4 expandtab: */
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits