cryptohome: build for tpm2 is broken |
||
Issue description
USE="tpm2" emerge cryptohome fails due to a warning in tpm2_impl.cc:
../../../cryptohome-9999/platform2/cryptohome/tpm2_impl.cc:100:42: error: | has lower precedence than !=; != will be evaluated first [-Werror,-Wparentheses]
if (flags != Tpm::kTpmNvramWriteDefine | Tpm::kTpmNvramBindToPCR0) {
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^
../../../cryptohome-9999/platform2/cryptohome/tpm2_impl.cc:100:42: note: place parentheses around the '!=' expression to silence this warning
if (flags != Tpm::kTpmNvramWriteDefine | Tpm::kTpmNvramBindToPCR0) {
^
( )
../../../cryptohome-9999/platform2/cryptohome/tpm2_impl.cc:100:42: note: place parentheses around the | expression to evaluate it first
if (flags != Tpm::kTpmNvramWriteDefine | Tpm::kTpmNvramBindToPCR0) {
^
( )
1 error generated.
,
Jun 15 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromiumos/platform2/+/5ca44e1e21031845f1963611b819688be708e8d3 commit 5ca44e1e21031845f1963611b819688be708e8d3 Author: Andrey Pronin <apronin@google.com> Date: Tue Jun 14 17:32:38 2016 cryptohome: fix checking flags for tpm2 Fixing operator precedence that breaks build with USE="tpm2" BUG= chromium:619979 TEST=USE="tpm2" emerge-$BOARD cryptohome Change-Id: Ifd4234f60788084cc9cb0d160c8dbf1824044f9b Reviewed-on: https://chromium-review.googlesource.com/352254 Commit-Ready: Andrey Pronin <apronin@chromium.org> Tested-by: Andrey Pronin <apronin@chromium.org> Reviewed-by: Randall Spangler <rspangler@chromium.org> [modify] https://crrev.com/5ca44e1e21031845f1963611b819688be708e8d3/cryptohome/tpm2_impl.cc
,
Jun 21 2016
|
||
►
Sign in to add a comment |
||
Comment 1 by apronin@chromium.org
, Jun 14 2016