diff options
Diffstat (limited to 'util')
-rw-r--r-- | util/uuid.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/util/uuid.c b/util/uuid.c index a4523216..82e310b9 100644 --- a/util/uuid.c +++ b/util/uuid.c @@ -9,6 +9,7 @@ bool generate_uuid(char out[static 37]) { return true; } #else +#include <assert.h> #include <string.h> #include <stdlib.h> @@ -26,7 +27,7 @@ bool generate_uuid(char out[static 37]) { } assert(strlen(str) + 1 == 37); - memcpy(out, str, sizeof(out)); + memcpy(out, str, 37); free(str); return true; } |