mirror of
https://github.com/NationalSecurityAgency/ghidra.git
synced 2025-10-05 10:49:34 +02:00
GT-3530 corrected improper use of bitSize
This commit is contained in:
parent
d1d5f9ea16
commit
fc5c68bc2b
1 changed files with 2 additions and 2 deletions
|
@ -421,9 +421,9 @@ public class BitFieldDataType extends AbstractDataType {
|
|||
if (intDT.getFormatSettingsDefinition().getFormat(
|
||||
settings) == FormatSettingsDefinition.CHAR) {
|
||||
if (big.signum() < 0) {
|
||||
big = big.add(BigInteger.valueOf(2).pow(bitSize));
|
||||
big = big.add(BigInteger.valueOf(2).pow(effectiveBitSize));
|
||||
}
|
||||
int bytesLen = BitFieldDataType.getMinimumStorageSize(bitSize);
|
||||
int bytesLen = BitFieldDataType.getMinimumStorageSize(effectiveBitSize);
|
||||
byte[] bytes = DataConverter.getInstance(buf.isBigEndian()).getBytes(big, bytesLen);
|
||||
|
||||
return StringDataInstance.getCharRepresentation(this, bytes, settings);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue