On 11/27/2016 11:48 AM, Laurent Vivier wrote: >> > + return (int64_t)(data << d.bofs) >> (64 - len); > We must use d.len instead of len, otherwise we shift with 32bit value. > > - return (int64_t)(data << d.bofs) >> (64 - len); > + return (int64_t)(data << d.bofs) >> (64 - d.len);
Whoops, yes. r~