[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20230121203230.27624-34-ebiggers@kernel.org>
Date: Sat, 21 Jan 2023 12:32:25 -0800
From: Eric Biggers <ebiggers@...nel.org>
To: linux-ext4@...r.kernel.org
Subject: [PATCH 33/38] misc/mke2fs: fix a -Wunused-variable warning in PRS()
From: Eric Biggers <ebiggers@...gle.com>
This showed up when building for Windows.
Signed-off-by: Eric Biggers <ebiggers@...gle.com>
---
misc/mke2fs.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/misc/mke2fs.c b/misc/mke2fs.c
index 24cc14750..7028d3935 100644
--- a/misc/mke2fs.c
+++ b/misc/mke2fs.c
@@ -1598,7 +1598,6 @@ static void PRS(int argc, char *argv[])
* Finally, we complain about fs_blocks_count > 2^32 on a non-64bit fs.
*/
blk64_t fs_blocks_count = 0;
- long sysval;
int s_opt = -1, r_opt = -1;
char *fs_features = 0;
int fs_features_size = 0;
@@ -1632,9 +1631,12 @@ static void PRS(int argc, char *argv[])
#define _SC_PAGESIZE _SC_PAGE_SIZE
#endif
#ifdef _SC_PAGESIZE
- sysval = sysconf(_SC_PAGESIZE);
- if (sysval > 0)
- sys_page_size = sysval;
+ {
+ long sysval = sysconf(_SC_PAGESIZE);
+
+ if (sysval > 0)
+ sys_page_size = sysval;
+ }
#endif /* _SC_PAGESIZE */
#endif /* HAVE_SYSCONF */
--
2.39.0
Powered by blists - more mailing lists