Save integer to memory as big endian.
| 94 | |
| 95 | // Save integer to memory as big endian. |
| 96 | inline void RawPutBE4(uint32 i,byte *mem) |
| 97 | { |
| 98 | #if defined(USE_MEM_BYTESWAP) && defined(_MSC_VER) |
| 99 | *(uint32*)mem = _byteswap_ulong(i); |
| 100 | #elif defined(USE_MEM_BYTESWAP) && (__GNUC__ > 3) && (__GNUC_MINOR__ > 2) |
| 101 | *(uint32*)mem = __builtin_bswap32(i); |
| 102 | #else |
| 103 | mem[0]=byte(i>>24); |
| 104 | mem[1]=byte(i>>16); |
| 105 | mem[2]=byte(i>>8); |
| 106 | mem[3]=byte(i); |
| 107 | #endif |
| 108 | } |
| 109 | |
| 110 | |
| 111 | inline uint32 ByteSwap32(uint32 i) |
no outgoing calls
no test coverage detected