if (cb->log_send_errors && status < 0)
{
char errbuf[1024];
+ const char *protocol = cb->protocol ? cb->protocol : WG_DEFAULT_PROTOCOL;
+
ERROR ("write_graphite plugin: send to %s:%s (%s) failed with status %zi (%s)",
- cb->node, cb->service, cb->protocol,
+ cb->node, cb->service, protocol,
status, sstrerror (errno, errbuf, sizeof (errbuf)));