QUIC: fix old versions of GQUIC on big-endian machines (#1387)
Credits to @viniciussn (see #1312)
This commit is contained in:
@@ -239,7 +239,7 @@ static uint16_t gquic_get_u16(const uint8_t *buf, uint32_t version)
|
|||||||
{
|
{
|
||||||
if(version >= V_Q039)
|
if(version >= V_Q039)
|
||||||
return ntohs(*(uint16_t *)buf);
|
return ntohs(*(uint16_t *)buf);
|
||||||
return (*(uint16_t *)buf);
|
return le16toh(*(uint16_t *)buf);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user