From c488b8a8fcde161c77d4e8a699a6b7c11f218f02 Mon Sep 17 00:00:00 2001 From: Jonas 'Sortie' Termansen Date: Fri, 10 May 2024 12:15:59 +0000 Subject: [PATCH] Fix extfs(8) mount warnings. --- ext/extfs.cpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/ext/extfs.cpp b/ext/extfs.cpp index 23d922bc..3109687c 100644 --- a/ext/extfs.cpp +++ b/ext/extfs.cpp @@ -270,16 +270,16 @@ int main(int argc, char* argv[]) if ( write && sb.s_feature_ro_compat & ~EXT2_FEATURE_RO_COMPAT_SUPPORTED ) { - warn("warning: %s: Uses unsupported and incompatible features, " - "falling back to read-only access\n", device_path); + warnx("warning: %s: Uses unsupported and incompatible features, " + "falling back to read-only access", device_path); // TODO: Modify the file descriptor such that writing fails! write = false; } // Check whether any features are in use that we can safely disregard. if ( sb.s_feature_compat & ~EXT2_FEATURE_COMPAT_SUPPORTED ) - warn("%s: Filesystem uses unsupported but compatible features\n", - device_path); + warnx("%s: Filesystem uses unsupported but compatible features", + device_path); // Check the block size is sane. 64 KiB may have issues, 32 KiB then. if ( sb.s_log_block_size > (15-10) /* 32 KiB blocks */ ) @@ -287,7 +287,7 @@ int main(int argc, char* argv[]) // Check whether the filesystem was unmounted cleanly. if ( sb.s_state != EXT2_VALID_FS ) - warn("warning: %s: Filesystem wasn't unmounted cleanly\n", device_path); + warnx("warning: %s: Filesystem wasn't unmounted cleanly", device_path); uint32_t block_size = 1024U << sb.s_log_block_size;