http://bugs.winehq.org/show_bug.cgi?id=35353
Bug ID: 35353 Summary: mono/eglib/src/gutf8.c: many bad if expressions ? Product: Wine Version: unspecified Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: programs Assignee: wine-bugs@winehq.org Reporter: dcb314@hotmail.com Classification: Unclassified
I just ran the static analyser "cppcheck" over the source code of wine-mono-4.5.2. It said many things including
1.
mono/eglib/src/gutf8.c:294]: (style) Expression '(X & 0xc0) != 0xb0' is always true.
Source code is
if ((*p & 0xc0) != 0xb0)
Suggest code rework.
2.
[../../../mono/eglib/src/gutf8.c:306]: (style) Expression '(X & 0xc0) == 0xb0' is always false. [../../../mono/eglib/src/gutf8.c:331]: (style) Expression '(X & 0xc0) == 0xb0' is always false. [../../../mono/eglib/src/gutf8.c:294]: (style) Expression '(X & 0xc0) != 0xb0' is always true. [../../../mono/eglib/src/gutf8.c:306]: (style) Expression '(X & 0xc0) == 0xb0' is always false. [../../../mono/eglib/src/gutf8.c:331]: (style) Expression '(X & 0xc0) == 0xb0' is always false.