mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 14:35:26 +00:00
Shut up MSVC++ compiler warning about loss of precision when assigning
8 bits masked out of a 32 bit int to individual bytes.
This commit is contained in:
@@ -378,10 +378,10 @@ isc_buffer_putuint32(isc_buffer_t *b, isc_uint32_t val)
|
|||||||
cp = b->base;
|
cp = b->base;
|
||||||
cp += b->used;
|
cp += b->used;
|
||||||
b->used += 4;
|
b->used += 4;
|
||||||
cp[0] = (val & 0xff000000) >> 24;
|
cp[0] = (unsigned char)((val & 0xff000000) >> 24);
|
||||||
cp[1] = (val & 0x00ff0000) >> 16;
|
cp[1] = (unsigned char)((val & 0x00ff0000) >> 16);
|
||||||
cp[2] = (val & 0x0000ff00) >> 8;
|
cp[2] = (unsigned char)((val & 0x0000ff00) >> 8);
|
||||||
cp[3] = (val & 0x000000ff);
|
cp[3] = (unsigned char)(val & 0x000000ff);
|
||||||
}
|
}
|
||||||
|
|
||||||
isc_result_t
|
isc_result_t
|
||||||
|
Reference in New Issue
Block a user