libsepol: fix unknown magic section number error message
When running hll/pp on some invalid policy module, it can output: libsepol.sepol_module_package_read: unknown magic number at section 1, offset: 251, number: 0x The last number looks funny and was caused by using "%ux". "u" is not a prefix like "l", "h", "z"... and "%x" already expects an unsigned integer (cf. http://man7.org/linux/man-pages/man3/printf.3.html). Signed-off-by: Nicolas Iooss <nicolas.iooss@m4x.org>
This commit is contained in:
parent
d10725649e
commit
2907caa33c
|
@ -627,7 +627,7 @@ int sepol_module_package_read(sepol_module_package_t * mod,
|
|||
default:
|
||||
/* unknown section, ignore */
|
||||
ERR(file->handle,
|
||||
"unknown magic number at section %u, offset: %zx, number: %ux ",
|
||||
"unknown magic number at section %u, offset: %zx, number: %x ",
|
||||
i, offsets[i], le32_to_cpu(buf[0]));
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue