diff options
author | Caolán McNamara <caolanm@redhat.com> | 2015-01-25 21:24:41 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2015-01-25 21:25:26 +0000 |
commit | 6347df7af9a6c095da49c353aa8cc31914da8510 (patch) | |
tree | 042374b5aa5e38ad71e28ebab3b0be832c7cf210 /xmlsecurity | |
parent | e11fe1886a58498899d7b074348186a46c5f6ac6 (diff) |
coverity#1266458 Argument cannot be negative
and
coverity#1266464 Argument cannot be negative
Change-Id: I27fb7789cd37046fcdaeaaa801d6dc0547a8afa1
Diffstat (limited to 'xmlsecurity')
-rw-r--r-- | xmlsecurity/source/helper/xsecctl.cxx | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/xmlsecurity/source/helper/xsecctl.cxx b/xmlsecurity/source/helper/xsecctl.cxx index 66edb6a4917e..1225097da3fe 100644 --- a/xmlsecurity/source/helper/xsecctl.cxx +++ b/xmlsecurity/source/helper/xsecctl.cxx @@ -1019,10 +1019,8 @@ void SAL_CALL XSecController::signatureCreated( sal_Int32 securityId, com::sun:: throw (com::sun::star::uno::RuntimeException, std::exception) { int index = findSignatureInfor(securityId); - DBG_ASSERT( index != -1, "Signature Not Found!" ); - - SignatureInformation& signatureInfor = m_vInternalSignatureInformations[index].signatureInfor; - + assert(index != -1 && "Signature Not Found!"); + SignatureInformation& signatureInfor = m_vInternalSignatureInformations.at(index).signatureInfor; signatureInfor.nStatus = nResult; } @@ -1033,10 +1031,8 @@ void SAL_CALL XSecController::signatureVerified( sal_Int32 securityId, com::sun: throw (com::sun::star::uno::RuntimeException, std::exception) { int index = findSignatureInfor(securityId); - DBG_ASSERT( index != -1, "Signature Not Found!" ); - - SignatureInformation& signatureInfor = m_vInternalSignatureInformations[index].signatureInfor; - + assert(index != -1 && "Signature Not Found!"); + SignatureInformation& signatureInfor = m_vInternalSignatureInformations.at(index).signatureInfor; signatureInfor.nStatus = nResult; } |