mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
Use builtin bitswap for endian on windows
Signed-off-by: R4SAS <r4sas@i2pmail.org>
This commit is contained in:
parent
54b7d46f5a
commit
53f19e4050
2 changed files with 18 additions and 40 deletions
|
@ -50,42 +50,3 @@ uint64_t be64toh(uint64_t big64)
|
|||
return u64.raw_value;
|
||||
}
|
||||
#endif
|
||||
|
||||
/* it can be used in Windows 8
|
||||
#include <Winsock2.h>
|
||||
|
||||
uint16_t htobe16(uint16_t int16)
|
||||
{
|
||||
return htons(int16);
|
||||
}
|
||||
|
||||
uint32_t htobe32(uint32_t int32)
|
||||
{
|
||||
return htonl(int32);
|
||||
}
|
||||
|
||||
uint64_t htobe64(uint64_t int64)
|
||||
{
|
||||
// http://msdn.microsoft.com/en-us/library/windows/desktop/jj710199%28v=vs.85%29.aspx
|
||||
//return htonll(int64);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
||||
uint16_t be16toh(uint16_t big16)
|
||||
{
|
||||
return ntohs(big16);
|
||||
}
|
||||
|
||||
uint32_t be32toh(uint32_t big32)
|
||||
{
|
||||
return ntohl(big32);
|
||||
}
|
||||
|
||||
uint64_t be64toh(uint64_t big64)
|
||||
{
|
||||
// http://msdn.microsoft.com/en-us/library/windows/desktop/jj710199%28v=vs.85%29.aspx
|
||||
//return ntohll(big64);
|
||||
return 0;
|
||||
}
|
||||
*/
|
Loading…
Add table
Add a link
Reference in a new issue