mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-07-01 11:32:21 +08:00
little endian mask fix (#330)
This commit is contained in:
@@ -31,6 +31,7 @@ namespace {
|
||||
uint64_t dat = (ival & ((1ULL << sig.b2)-1)) << shift;
|
||||
if (sig.is_little_endian) {
|
||||
dat = ReverseBytes(dat);
|
||||
mask = ReverseBytes(mask);
|
||||
}
|
||||
ret &= ~mask;
|
||||
ret |= dat;
|
||||
|
||||
Reference in New Issue
Block a user