aboutsummaryrefslogtreecommitdiff
path: root/PolicySigned.c
diff options
context:
space:
mode:
authorVadim Bendebury <vbendeb@chromium.org>2015-06-04 20:32:54 -0700
committerChromeOS Commit Bot <chromeos-commit-bot@chromium.org>2015-06-05 23:48:55 +0000
commit99e88835efdddfb4e01ebfe07f668379d64dda64 (patch)
treeb675e5a0e6abe2cff42b8871ad1ddbfb7db2f15f /PolicySigned.c
parent4ea50761f7fd558364a09f79942773679916776b (diff)
downloadtpm2-99e88835efdddfb4e01ebfe07f668379d64dda64.tar.gz
build: fix {INT}_TO_ARRAY macros
Macros used to convert different size integers into arrays return integers themselves using the comma operator. GCC throws a 'value computed but not ussed' in this case, which can be pacified by appending (void) in front of the macro invocation. For some reason different invocations trigger GCC warnings inside and outside chroot. But the bottom line is that the code does not used the values returned by the macros, so a better fix is to change the macros not to return the values. BUG=none TEST=make succeeds for x86 both inside and outside chroot now. Change-Id: I8105b8051aee2cb72409dd70c5e5cfa4f841b549 Signed-off-by: Vadim Bendebury <vbendeb@chromium.org> Reviewed-on: https://chromium-review.googlesource.com/275394 Reviewed-by: Bill Richardson <wfrichar@chromium.org>
Diffstat (limited to 'PolicySigned.c')
-rw-r--r--PolicySigned.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/PolicySigned.c b/PolicySigned.c
index e99c151..b95fb9c 100644
--- a/PolicySigned.c
+++ b/PolicySigned.c
@@ -128,7 +128,7 @@ TPM2_PolicySigned(
// used has the side-effect of making the returned value a big-endian,
// 64-bit value that is byte aligned.
out->timeout.t.size = sizeof(UINT64);
- (void)UINT64_TO_BYTE_ARRAY(authTimeout, out->timeout.t.buffer);
+ UINT64_TO_BYTE_ARRAY(authTimeout, out->timeout.t.buffer);
// Compute policy ticket
TicketComputeAuth(TPM_ST_AUTH_SIGNED, EntityGetHierarchy(in->authObject),