From 39b2386b3369cb795dad4e2f8ae6b74959acaf16 Mon Sep 17 00:00:00 2001 From: Svyatoslav Date: Wed, 14 Jun 2017 12:10:57 +0300 Subject: [PATCH] Fixes identical sub-expressions for certificate verification An issue has been found by using PVS-Studio analyzer. Analyzer warning: V501 There are identical sub-expressions to the left and to the right of the '!=' operator: subject != subject. Closes #3399 --- PowerEditor/src/MISC/Common/verifySignedfile.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/PowerEditor/src/MISC/Common/verifySignedfile.cpp b/PowerEditor/src/MISC/Common/verifySignedfile.cpp index 591b4917e..5b69157df 100644 --- a/PowerEditor/src/MISC/Common/verifySignedfile.cpp +++ b/PowerEditor/src/MISC/Common/verifySignedfile.cpp @@ -247,7 +247,7 @@ bool VerifySignedLibrary(const wstring& filepath, OutputDebugString(TEXT("VerifyLibrary: Invalid certificate display name\n")); } - if ( status && !cert_subject.empty() && subject != subject) + if ( status && !cert_subject.empty() && cert_subject != subject) { status = false; OutputDebugString(TEXT("VerifyLibrary: Invalid certificate subject\n"));