Improve logging:

- don't hardcode function name
- use LOG_DEBUG for such a debug message
- print error value
This commit is contained in:
glebius 2011-11-22 19:42:17 +00:00
parent 4e2f5ddf34
commit ec7618f8d2

View File

@ -1475,7 +1475,7 @@ ifa_add_loopback_route(struct ifaddr *ifa, struct sockaddr *ia)
RT_REMREF(rt);
RT_UNLOCK(rt);
} else if (error != 0)
log(LOG_INFO, "ifa_add_loopback_route: insertion failed\n");
log(LOG_DEBUG, "%s: insertion failed: %u\n", __func__, error);
return (error);
}
@ -1499,7 +1499,7 @@ ifa_del_loopback_route(struct ifaddr *ifa, struct sockaddr *ia)
error = rtrequest1_fib(RTM_DELETE, &info, NULL, 0);
if (error != 0)
log(LOG_INFO, "ifa_del_loopback_route: deletion failed\n");
log(LOG_DEBUG, "%s: deletion failed: %u\n", __func__, error);
return (error);
}