Michael Stefaniuc : ole32: Remove an always true conditional subexpression (PVS-Studio).

Alexandre Julliard julliard at wine.codeweavers.com
Wed Feb 18 09:57:18 CST 2015


Module: wine
Branch: master
Commit: 73019d5e208d8efc8848ad5a67b7af8979966811
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=73019d5e208d8efc8848ad5a67b7af8979966811

Author: Michael Stefaniuc <mstefani at redhat.de>
Date:   Wed Feb 18 00:09:03 2015 +0100

ole32: Remove an always true conditional subexpression (PVS-Studio).

---

 dlls/ole32/storage32.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dlls/ole32/storage32.c b/dlls/ole32/storage32.c
index 26fc0d8..5e434e0 100644
--- a/dlls/ole32/storage32.c
+++ b/dlls/ole32/storage32.c
@@ -2969,7 +2969,7 @@ static HRESULT StorageImpl_GrabLocks(StorageImpl *This, DWORD openFlags)
     hr = S_OK;
 
     /* First check for any conflicting locks. */
-    if (SUCCEEDED(hr) && (openFlags & STGM_PRIORITY) == STGM_PRIORITY)
+    if ((openFlags & STGM_PRIORITY) == STGM_PRIORITY)
         hr = StorageImpl_CheckLockRange(This, RANGELOCK_COMMIT, RANGELOCK_COMMIT, STG_E_LOCKVIOLATION);
 
     if (SUCCEEDED(hr) && (STGM_ACCESS_MODE(openFlags) != STGM_WRITE))




More information about the wine-cvs mailing list