From d376755655baefb1fc7eb228337626ec24dd24bc Mon Sep 17 00:00:00 2001 From: Robert Watson Date: Wed, 24 Jun 2009 10:46:03 +0000 Subject: [PATCH] Printf fewer warnings when adding a route to an atalk address fails; userspace will print the error. MFC after: 3 days --- sys/netatalk/at_control.c | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/sys/netatalk/at_control.c b/sys/netatalk/at_control.c index 02f080c32596..6332697cf8e0 100644 --- a/sys/netatalk/at_control.c +++ b/sys/netatalk/at_control.c @@ -830,7 +830,6 @@ static int aa_addsingleroute(struct ifaddr *ifa, struct at_addr *addr, struct at_addr *mask) { - int error; #if 0 printf("aa_addsingleroute: %x.%x mask %x.%x ...\n", @@ -838,22 +837,15 @@ aa_addsingleroute(struct ifaddr *ifa, struct at_addr *addr, mask->s_node); #endif - error = aa_dosingleroute(ifa, addr, mask, RTM_ADD, RTF_UP); - if (error) - printf("aa_addsingleroute: error %d\n", error); - return (error); + return (aa_dosingleroute(ifa, addr, mask, RTM_ADD, RTF_UP)); } static int aa_delsingleroute(struct ifaddr *ifa, struct at_addr *addr, struct at_addr *mask) { - int error; - error = aa_dosingleroute(ifa, addr, mask, RTM_DELETE, 0); - if (error) - printf("aa_delsingleroute: error %d\n", error); - return (error); + return (aa_dosingleroute(ifa, addr, mask, RTM_DELETE, 0)); } static int