From 2f7d93cb50ad80d422243b74675f1f0f72d6e14f Mon Sep 17 00:00:00 2001 From: Sergei Trofimovich Date: Sat, 4 Jun 2011 11:19:24 +0300 Subject: [PATCH 24/28] mkfs.btrfs: fix error text in '-r' mode Smart gcc noticed use of uninitialized warning when compiled with -O0 flags: mkfs.c:1291: error: 'file' may be used uninitialized in this function Signed-off-by: Sergei Trofimovich Signed-off-by: Hugo Mills --- mkfs.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/mkfs.c b/mkfs.c index b93b874..e191b7f 100644 --- a/mkfs.c +++ b/mkfs.c @@ -1287,13 +1287,13 @@ int main(int ac, char **av) block_count = dev_block_count; } else { ac = 0; + file = output; fd = open_target(output); if (fd < 0) { fprintf(stderr, "unable to open the %s\n", file); exit(1); } - file = output; first_file = file; block_count = size_sourcedir(source_dir, sectorsize, &num_of_meta_chunks, &size_of_data); -- 1.7.5.2.353.g5df3e