Commit e21b10bb authored by Bernhard Link's avatar Bernhard Link

allow INT32_32 in VALUES as XSync adds that there

parent 9745aa21
......@@ -731,6 +731,21 @@ static size_t printLISTofVALUE(struct connection *c,const uint8_t *buffer,size_t
u32 = getCARD32(ofs); i32 = u32;
u16 = u32 & 65535; i16 = u16;
u8 = u32 & 255; i8 = u8;
if( v->type == ft_INT32_32 ) {
long long ll;
/* XSync suddenly has 64 bit values allowed in
* VALUES... */
if( buflen-ofs < 8 ) {
c++;
continue;
}
u32 = getCARD32(ofs + 4);
ll = (((long long)i32)<< 32LL) + (long long)u32;
fprintf(out, "%s=%lld", v->name, ll);
ofs += 8;v++;
continue;
}
if( v->type >= ft_BITMASK8 ) {
assert(v->type <= ft_BITMASK32 );
print_bitfield(v->name,v->constants,u32);
......
......@@ -93,7 +93,7 @@ static const struct base_type {
{ "BE32", ft_BE32, ALLOWS_CONSTANTS, 4},
{ "FRACTION16_16", ft_FRACTION16_16, 0, 4},
{ "FRACTION32_32", ft_FRACTION32_32, 0, 8},
{ "INT32_32", ft_INT32_32, 0, 8},
{ "INT32_32", ft_INT32_32, ELEMENTARY, 8},
{ "FIXED", ft_FIXED, 0, 4},
{ "FIXED1616", ft_FIXED, 0, 4},
{ "FIXED3232", ft_FIXED3232, 0, 8},
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment