Cast size_t to unsigned long.

printf expects unsigned long (%lu) argument, however, size_t doesn't
have to be declared as such. As %zu is C99 (but not C++), it shouldn't
be used directly. Instead, I have to cast value to the correct type.
This commit is contained in:
Konrad Borowski 2013-11-25 15:56:08 +01:00
parent 8ceb4b83a4
commit ac7a461070

View file

@ -188,7 +188,7 @@ void print_open_fds(void)
{
if (open_fds.at(i))
{
fprintf(stderr, "fd %lu\n", i);
fprintf(stderr, "fd %lu\n", (unsigned long) i);
}
}
}