major() and minor() return unsigned int, so the typecasts to uintmax_t are not needed. Signed-off-by: Jakub Wilk <jwilk@xxxxxxxxx> --- man2/ioctl_ns.2 | 12 ++++++------ man2/stat.2 | 6 +++--- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/man2/ioctl_ns.2 b/man2/ioctl_ns.2 index 95b39ccac..02c1dab11 100644 --- a/man2/ioctl_ns.2 +++ b/man2/ioctl_ns.2 @@ -293,9 +293,9 @@ main(int argc, char *argv[]) exit(EXIT_FAILURE); } printf("Device/Inode of owning user namespace is: " - "[%jx,%jx] / %ju\en", - (uintmax_t) major(sb.st_dev), - (uintmax_t) minor(sb.st_dev), + "[%x,%x] / %ju\en", + major(sb.st_dev), + minor(sb.st_dev), (uintmax_t) sb.st_ino); close(userns_fd); @@ -323,9 +323,9 @@ main(int argc, char *argv[]) perror("fstat\-parentns"); exit(EXIT_FAILURE); } - printf("Device/Inode of parent namespace is: [%jx,%jx] / %ju\en", - (uintmax_t) major(sb.st_dev), - (uintmax_t) minor(sb.st_dev), + printf("Device/Inode of parent namespace is: [%x,%x] / %ju\en", + major(sb.st_dev), + minor(sb.st_dev), (uintmax_t) sb.st_ino); close(parent_fd); diff --git a/man2/stat.2 b/man2/stat.2 index 585a20484..bdd6d15e3 100644 --- a/man2/stat.2 +++ b/man2/stat.2 @@ -481,9 +481,9 @@ main(int argc, char *argv[]) exit(EXIT_FAILURE); } - printf("ID of containing device: [%jx,%jx]\en", - (uintmax_t) major(sb.st_dev), - (uintmax_t) minor(sb.st_dev)); + printf("ID of containing device: [%x,%x]\en", + major(sb.st_dev), + minor(sb.st_dev)); printf("File type: "); -- 2.37.2