[PATCH 1/1] ioctl_fat.2: use %04x to print volume id

From: Heinrich Schuchardt <hidden>
Date: 2016-05-07 08:42:52
Subsystem: the rest · Maintainer: Linus Torvalds

Leading zeroes should be used when display a FAT volume id.

Signed-off-by: Heinrich Schuchardt <redacted>
---
 man2/ioctl_fat.2 | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/man2/ioctl_fat.2 b/man2/ioctl_fat.2
index 4ae0e5d..875b57e 100644
--- a/man2/ioctl_fat.2
+++ b/man2/ioctl_fat.2
@@ -111,7 +111,7 @@ Typically the volume label is displayed to the user as a group of two
 .PP
 .in +4n
 .nf
-printf("Volume ID %4x-%4x\\n", id >> 16, id & 0xFFFF);
+printf("Volume ID %04x-%04x\\n", id >> 16, id & 0xFFFF);
 .fi
 .in
 .SS Reading short file names of a directory
@@ -403,7 +403,7 @@ main(int argc, char *argv[])
     /*
      * Format the output as two groups of 16 bits each.
      */
-    printf("Volume ID %4x\-%4x\\n", id >> 16, id & 0xFFFF);
+    printf("Volume ID %04x\-%04x\\n", id >> 16, id & 0xFFFF);
 
     close(fd);
 
-- 
2.1.4

--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help