Fix regression in ASN.1 int type generation
The 64-bit integer support changed the logic for deciding when an INTEGER should map to a signed or unsigned 32- or 64-bit integer type. The upshot is that two places where we had {0, INT_MAX} ranges needed to be changed to be {0, UINT_MAX}. We need to tweak the integer type mapping logic to have a bias for unsigned integer types. Unsigned is better.
This commit is contained in:
@@ -752,7 +752,7 @@ define_type (int level, const char *name, const char *basename, Type *t, int typ
|
||||
case TBitString: {
|
||||
Member *m;
|
||||
Type i;
|
||||
struct range range = { 0, INT_MAX };
|
||||
struct range range = { 0, UINT_MAX };
|
||||
|
||||
i.type = TInteger;
|
||||
i.range = ⦥
|
||||
@@ -851,7 +851,7 @@ define_type (int level, const char *name, const char *basename, Type *t, int typ
|
||||
case TSetOf:
|
||||
case TSequenceOf: {
|
||||
Type i;
|
||||
struct range range = { 0, INT_MAX };
|
||||
struct range range = { 0, UINT_MAX };
|
||||
|
||||
getnewbasename(&newbasename, typedefp, basename, name);
|
||||
|
||||
|
Reference in New Issue
Block a user