Fix a number of format string issues

e36f3c0 : Adds compiler type checking of format strings.

7466cf9: flog(LOG_INFO, "sending stop adverts", pidfile); clearly has an extra unintented argument.

1a85e4d: Use correct format for size_t (%zu)