* @brief Packs a 16-bit unsigned integer into a little-endian QByteArray. */
| 259 | * @brief Packs a 16-bit unsigned integer into a little-endian QByteArray. |
| 260 | */ |
| 261 | static QByteArray packU16LE(uint16_t v) |
| 262 | { |
| 263 | uint8_t out[2]; |
| 264 | little_endian_memcpy(out, &v, sizeof(v)); |
| 265 | return QByteArray(reinterpret_cast<char*>(out), sizeof(out)); |
| 266 | } |
| 267 | |
| 268 | /** |
| 269 | * @brief Packs a 32-bit unsigned integer into a big-endian QByteArray. |
no test coverage detected