Skip to content

Commit

Permalink
Use __FUNC__ instead of function for protability
Browse files Browse the repository at this point in the history
It is #defined to __FUNCTION__ or to __func__ depending on what configure detected.
  • Loading branch information
wtoorop committed Feb 19, 2017
1 parent b3a06f1 commit 4b6962c
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions src/mdns.c
Expand Up @@ -83,7 +83,7 @@ static void
mdns_cleanup(getdns_network_req *netreq)
{
DEBUG_MDNS("%s %-35s: MSG: %p\n",
MDNS_DEBUG_CLEANUP, __FUNCTION__, netreq);
MDNS_DEBUG_CLEANUP, __FUNC__, netreq);
getdns_dns_req *dnsreq = netreq->owner;

GETDNS_CLEAR_EVENT(dnsreq->loop, &netreq->event);
Expand All @@ -109,7 +109,7 @@ mdns_timeout_cb(void *userarg)
{
getdns_network_req *netreq = (getdns_network_req *)userarg;
DEBUG_MDNS("%s %-35s: MSG: %p\n",
MDNS_DEBUG_CLEANUP, __FUNCTION__, netreq);
MDNS_DEBUG_CLEANUP, __FUNC__, netreq);

/* TODO: do we need a retry logic here? */

Expand Down Expand Up @@ -143,7 +143,7 @@ mdns_udp_read_cb(void *userarg)
getdns_dns_req *dnsreq = netreq->owner;
ssize_t read;
DEBUG_MDNS("%s %-35s: MSG: %p \n", MDNS_DEBUG_READ,
__FUNCTION__, netreq);
__FUNC__, netreq);

GETDNS_CLEAR_EVENT(dnsreq->loop, &netreq->event);

Expand Down Expand Up @@ -197,7 +197,7 @@ mdns_udp_write_cb(void *userarg)
int r;

DEBUG_MDNS("%s %-35s: MSG: %p \n", MDNS_DEBUG_WRITE,
__FUNCTION__, netreq);
__FUNC__, netreq);

GETDNS_CLEAR_EVENT(dnsreq->loop, &netreq->event);

Expand Down Expand Up @@ -245,7 +245,7 @@ mdns_udp_write_cb(void *userarg)
getdns_return_t
_getdns_submit_mdns_request(getdns_network_req *netreq)
{
DEBUG_MDNS("%s %-35s: MSG: %p TYPE: %d\n", MDNS_DEBUG_ENTRY, __FUNCTION__,
DEBUG_MDNS("%s %-35s: MSG: %p TYPE: %d\n", MDNS_DEBUG_ENTRY, __FUNC__,
netreq, netreq->request_type);
int fd = -1;
getdns_dns_req *dnsreq = netreq->owner;
Expand Down

0 comments on commit 4b6962c

Please sign in to comment.