mirror of https://github.com/mkerrisk/man-pages
offsetof.3: Use "%zu" rather than "%zd" when printing 'size_t' values
Signed-off-by: Alejandro Colomar <colomar.6.4.3@gmail.com> Signed-off-by: Michael Kerrisk <mtk.manpages@gmail.com>
This commit is contained in:
parent
288d42bc37
commit
2bbfed1b16
|
@ -93,10 +93,10 @@ main(void)
|
|||
|
||||
/* Output is compiler dependent */
|
||||
|
||||
printf("offsets: i=%zd; c=%zd; d=%zd a=%zd\en",
|
||||
printf("offsets: i=%zu; c=%zu; d=%zu a=%zu\en",
|
||||
offsetof(struct s, i), offsetof(struct s, c),
|
||||
offsetof(struct s, d), offsetof(struct s, a));
|
||||
printf("sizeof(struct s)=%zd\en", sizeof(struct s));
|
||||
printf("sizeof(struct s)=%zu\en", sizeof(struct s));
|
||||
|
||||
exit(EXIT_SUCCESS);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue