message: Fix format-nonliteral warnings
diff: @@ -30,11 +30,11 @@ using namespace caf;
  namespace {
  -template <class... Ts>
  -void print(const char* format, Ts... xs) {
  - char buf[200];
  - snprintf(buf, 200, format, xs...);
  - CAF_MESSAGE(buf);
  +#define PRINT(format, ...) \
  + { \
  + char buf[200]; \
  + snprintf(buf, 200, format, __VA_ARGS__); \
  + CAF_MESSAGE(buf); \
  }
  struct fixture {
  @@ -53,11 +53,11 @@ struct fixture {
  int32_t t = total_time;
  int32_t m = t > 0 ? std::max((c * n) / t, 1) : 1;
  int32_t b = t > 0 ? std::max((d * n) / t, 1) : 1;
  - print("with a cycle C = %ldns, desied complexity D = %ld,", c, d);
  - print("number of items N = %ld, and time delta t = %ld:", n, t);
  - print("- throughput M = max(C * N / t, 1) = max(%ld * %ld / %ld, 1) = %ld",
  + PRINT("with a cycle C = %dns, desied complexity D = %d,", c, d);
  + PRINT("number of items N = %d, and time delta t = %d:", n, t);
  + PRINT("- throughput M = max(C * N / t, 1) = max(%d * %d / %d, 1) = %d",
  c, n, t, m);
  - print("- items/batch B = max(D * N / t, 1) = max(%ld * %ld / %ld, 1) = %ld",
  + PRINT("- items/batch B = max(D * N / t, 1) = max(%d * %d / %d, 1) = %d",
  d, n, t, b);
  auto cr = x.calculate(timespan(c), timespan(d));
  CAF_CHECK_EQUAL(cr.items_per_batch, b);
  