This commit is contained in:
1 parent
9055c5c825
commit
5e67c596b9
43 files changed
+476
-450
No files matched your search
+6
-6
@@ -15,19 +15,19 @@ struct UUID4 {
|
||||
u64 low;
|
||||
};
|
||||
|
||||
wp_intern UUID4 generate_uuid4(void);
|
||||
wp_intern void uuid4_to_uuid(const UUID4* uuid4, WpUuid *uuid);
|
||||
wp_intern UUID4 genUuid4(void);
|
||||
wp_intern void uuid4ToUuid(const UUID4* uuid4, WpUuid *uuid);
|
||||
|
||||
WpUuid *wpUuidInitUuid4(WpUuid *uuid) {
|
||||
wpDebugAssert(uuid != NULL, "`uuid` should not be NULL");
|
||||
|
||||
UUID4 uuid4 = generate_uuid4();
|
||||
uuid4_to_uuid(&uuid4, uuid);
|
||||
UUID4 uuid4 = genUuid4();
|
||||
uuid4ToUuid(&uuid4, uuid);
|
||||
|
||||
return uuid;
|
||||
}
|
||||
|
||||
wp_intern UUID4 generate_uuid4(void) {
|
||||
wp_intern UUID4 genUuid4(void) {
|
||||
wp_persist WpXor256State state = {0};
|
||||
wp_persist b8 initialised = false;
|
||||
|
||||
@@ -47,7 +47,7 @@ wp_intern UUID4 generate_uuid4(void) {
|
||||
return uuid;
|
||||
}
|
||||
|
||||
wp_intern void uuid4_to_uuid(const UUID4* uuid4, WpUuid *uuid) {
|
||||
wp_intern void uuid4ToUuid(const UUID4* uuid4, WpUuid *uuid) {
|
||||
u64 group1 = uuid4->high >> 32;
|
||||
u64 group2 = (uuid4->high << 32) >> 48;
|
||||
u64 group3 = (uuid4->high << 48) >> 48;
|
||||
|
||||
Reference in new issue
Block a user