[Bug 37120] New: PVS-Studio Error: Equivalent branches of if operator
https://bugs.winehq.org/show_bug.cgi?id=37120 Bug ID: 37120 Summary: PVS-Studio Error: Equivalent branches of if operator Product: Wine Version: 1.7.22 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown Assignee: wine-bugs(a)winehq.org Reporter: lukebenes(a)hotmail.com Equivalent branches of if operator V523 The 'then' statement is equivalent to the 'else' statement. filedlg.c 3302 if(pDIStruct->itemID == liInfos->uSelectedItem) { ilItemImage = (HIMAGELIST) SHGetFileInfoW ( (LPCWSTR) tmpFolder->pidlItem, 0, &sfi, sizeof (sfi), shgfi_flags ); } else { ilItemImage = (HIMAGELIST) SHGetFileInfoW ( (LPCWSTR) tmpFolder->pidlItem, 0, &sfi, sizeof (sfi), shgfi_flags ); } This code is either excessive or contains a typo. V523 The 'then' statement is equivalent to the 'else' statement. genres.c 1130 ... if(win32) { put_word(res, 0); /* Reserved */ /* FIXME: The ResType in the NEWHEADER structure should * contain 14 according to the MS win32 doc. This is * not the case with the BRC compiler and I really doubt * the latter. Putting one here is compliant to win16 spec, * but who knows the true value? */ put_word(res, 1); /* ResType */ put_word(res, icog->nicon); for(ico = icog->iconlist; ico; ico = ico->next) { ... } } else /* win16 */ { put_word(res, 0); /* Reserved */ put_word(res, 1); /* ResType */ put_word(res, icog->nicon); for(ico = icog->iconlist; ico; ico = ico->next) { ... } } ... One of the repeating branches is commented. Perhaps this is an incomplete fragment, not an error, but I decided to point it out anyway. details on the V523 error here: http://www.viva64.com/en/d/0112/ -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=37120 Luke <lukebenes(a)hotmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- URL| |http://www.viva64.com/en/b/ | |0272/ -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=37120 --- Comment #1 from Bruno Jesus <00cpxxx(a)gmail.com> --- First problem fixed by: http://source.winehq.org/git/wine.git/commitdiff/c4747f46cfa83a69801f6e961a9... -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=37120 André H. <nerv(a)dawncrow.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Fixed by SHA1| |9b810cd6e884facde7152a79a64 | |74c3637b260ee Status|UNCONFIRMED |RESOLVED CC| |nerv(a)dawncrow.de Resolution|--- |FIXED --- Comment #2 from André H. <nerv(a)dawncrow.de> --- (In reply to Bruno Jesus from comment #1)
First problem fixed by: http://source.winehq.org/git/wine.git/commitdiff/ c4747f46cfa83a69801f6e961a938ca91fbf80fc
And the second one was: https://source.winehq.org/git/wine.git/commitdiff/9b810cd6e884facde7152a79a6... -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=37120 Alexandre Julliard <julliard(a)winehq.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED --- Comment #3 from Alexandre Julliard <julliard(a)winehq.org> --- Closing bugs fixed in 1.7.31. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=37120 Anastasius Focht <focht(a)gmx.net> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |focht(a)gmx.net Component|-unknown |tools -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (1)
-
wine-bugs@winehq.org