Use __attribute__(format(printf) for logger

logger() accepts the same two last arguments as printf,
so marking it with the proper attribute allows compiler
to check for format string error during compile time.

This should help in catching errors such as the one introduced by
commit acb231d37f8581a31ab98be8deb499e0828f2012
and fixed by commit 444b793e693634a5003059234ea8c9497efe7c8d.

NOTE: I'm not sure how portable is this; gcc docs are silent about this.
We'll see if someone is using something other than gcc to compile vzctl.

Signed-off-by: Kir Kolyshkin <kir@openvz.org>
1 file changed