OpenAFS Master Repository branch, master, updated. openafs-devel-1_5_76-2738-g417df0d
Gerrit Code Review
Sat, 21 Jul 2012 20:23:41 -0700 (PDT)
The following commit has been merged in the master branch:
Author: Garrett Wollman <firstname.lastname@example.org>
Date: Sat Jul 21 00:04:58 2012 -0400
xdr: fix two old FIXMEs related to signed/unsigned arithmetic
It's implementation-defined whether the C '>>' operator, when
applied to a signed integer, is sign-extending or zero-filling.
If you want unsigned arithmetic, you have to ask for it explicitly.
One assumes the reason for the shift is to avoid overflow if the
returned size/count is later converted to a signed int, in which
case maybe it would be better to use INT_MAX here. This is the
minimal change necessary for correctness.
Reviewed-by: Derrick Brashear <email@example.com>
Tested-by: BuildBot <firstname.lastname@example.org>
Reviewed-by: Jeffrey Altman <email@example.com>
src/rx/xdr.c | 5 ++---
src/rx/xdr_array.c | 3 +--
2 files changed, 3 insertions(+), 5 deletions(-)
OpenAFS Master Repository