Created attachment 150735 [details] Fix emulators/open-vm-tools(-nox11) build with clang 3.5.0 The emulators/open-vm-tools and its -nox11 variant ports fail to compile with clang 3.5.0, due to the following -Werror warning: toolboxcmd-shrink.c:394:31: error: comparison of constant 'WIPER_ENABLED' (2) with boolean expression is always false [-Werror,-Wtautological-constant-out-of-range-compare] if (!ShrinkGetWiperState() == WIPER_ENABLED && !Wiper_IsWipeSupported(part)) { ~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~ 1 error generated. This is a logic error in the code, the ! operator applies to the left hand part of the == expression, while WIPER_ENABLED is one of three possible enum values. The code should use "ShrinkGetWiperState() != WIPER_ENABLED" instead.
Auto-assigned to maintainer swills@FreeBSD.org
A commit references this bug: Author: kwm Date: Sat Feb 14 13:36:49 UTC 2015 New revision: 378961 URL: https://svnweb.freebsd.org/changeset/ports/378961 Log: Fix build with clang 3.5.0. PR: 196108 Submitted by: dim@ Approved by: maintainer (via IRC) Changes: head/emulators/open-vm-tools/files/patch-toolbox__toolboxcmd-shrink.c