summaryrefslogtreecommitdiff
path: root/mkfs.c
diff options
context:
space:
mode:
authorDavid Sterba <dsterba@suse.com>2016-08-31 19:38:31 +0200
committerDavid Sterba <dsterba@suse.com>2016-09-21 13:44:24 +0200
commit7aaa1a92f621eec59a4ef834afefd831915a3521 (patch)
tree3fa23165d53ebdaad1cc71200f01e9c37295ac26 /mkfs.c
parent90e3e630c2f641f3ceca32672e8e3a8ac0ceae8a (diff)
btrfs-progs: mkfs: use preallocated buffers for config uuids
No need for dynamic allocation, the buffers are small, remove the now-useless error conditions. Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'mkfs.c')
-rw-r--r--mkfs.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mkfs.c b/mkfs.c
index adfc2786..4b88987c 100644
--- a/mkfs.c
+++ b/mkfs.c
@@ -1735,7 +1735,7 @@ int main(int argc, char **argv)
}
mkfs_cfg.label = label;
- mkfs_cfg.fs_uuid = fs_uuid;
+ memcpy(mkfs_cfg.fs_uuid, fs_uuid, sizeof(mkfs_cfg.fs_uuid));
memcpy(mkfs_cfg.blocks, blocks, sizeof(blocks));
mkfs_cfg.num_bytes = dev_block_count;
mkfs_cfg.nodesize = nodesize;