Paul Vriens : comctl32: Use struct member after check for NULL (Coverity).

Alexandre Julliard julliard at wine.codeweavers.com
Mon Jul 17 07:00:21 CDT 2006


Module: wine
Branch: refs/heads/master
Commit: 412aa2a10df2a6e4922dab070de4a1e2d8607bf4
URL:    http://source.winehq.org/git/?p=wine.git;a=commit;h=412aa2a10df2a6e4922dab070de4a1e2d8607bf4

Author: Paul Vriens <Paul.Vriens at xs4all.nl>
Date:   Sat Jul 15 20:27:24 2006 +0200

comctl32: Use struct member after check for NULL (Coverity).

---

 dlls/comctl32/listview.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/dlls/comctl32/listview.c b/dlls/comctl32/listview.c
index fb4ecf6..4d3819d 100644
--- a/dlls/comctl32/listview.c
+++ b/dlls/comctl32/listview.c
@@ -5618,10 +5618,12 @@ static BOOL LISTVIEW_GetSubItemRect(LIST
 {
     POINT Position;
     LVITEMW lvItem;
-    INT nColumn = lprc->top;
+    INT nColumn;
     
     if (!lprc) return FALSE;
 
+    nColumn = lprc->top;
+
     TRACE("(nItem=%d, nSubItem=%ld)\n", nItem, lprc->top);
     /* On WinNT, a subitem of '0' calls LISTVIEW_GetItemRect */
     if (lprc->top == 0)




More information about the wine-cvs mailing list