diff options
Diffstat (limited to 'src/common/uuid.cpp')
| -rw-r--r-- | src/common/uuid.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/common/uuid.cpp b/src/common/uuid.cpp index 51fe0abaa5..4b992c5df8 100644 --- a/src/common/uuid.cpp +++ b/src/common/uuid.cpp @@ -208,9 +208,9 @@ UUID UUID::MakeRandomRFC4122V4() { return uuid; } -UUID UUID::MakeRFC4122V5(std::span<u8, 20> sha1) { +UUID UUID::MakeRFC4122V5(std::span<u8, 16> sha1) { UUID uuid{}; - std::memcpy(&uuid.uuid, sha1.data(), sizeof(UUID)); + std::memcpy(&uuid.uuid, sha1.data(), sha1.size()); uuid.uuid[8] = 0x80 | (uuid.uuid[8] & 0x3F); uuid.uuid[6] = 0x50 | (uuid.uuid[6] & 0xF); return uuid; |
