From owner-p4-projects@FreeBSD.ORG Tue Jul 4 08:33:13 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 6D09716A4E7; Tue, 4 Jul 2006 08:33:13 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 4741516A4E2 for ; Tue, 4 Jul 2006 08:33:13 +0000 (UTC) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id EF1C843D68 for ; Tue, 4 Jul 2006 08:33:12 +0000 (GMT) (envelope-from piso@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.6/8.13.6) with ESMTP id k648XCYJ009760 for ; Tue, 4 Jul 2006 08:33:12 GMT (envelope-from piso@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.6/8.13.4/Submit) id k648XCgR009757 for perforce@freebsd.org; Tue, 4 Jul 2006 08:33:12 GMT (envelope-from piso@freebsd.org) Date: Tue, 4 Jul 2006 08:33:12 GMT Message-Id: <200607040833.k648XCgR009757@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to piso@freebsd.org using -f From: Paolo Pisati To: Perforce Change Reviews Cc: Subject: PERFORCE change 100550 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Jul 2006 08:33:13 -0000 http://perforce.freebsd.org/chv.cgi?CH=100550 Change 100550 by piso@piso_newluxor on 2006/07/04 08:32:31 Fixes a bunch of warnings: -axe empty if statement -axe unused vars -include "err.h" -return 1 if the function is supposed to return an int Affected files ... .. //depot/projects/soc2005/libalias/sys/netinet/libalias/alias.c#4 edit Differences ... ==== //depot/projects/soc2005/libalias/sys/netinet/libalias/alias.c#4 (text+ko) ==== @@ -137,6 +137,7 @@ #include #include #else +#include #include "alias.h" #include "alias_local.h" #include "alias_mod.h" @@ -741,8 +742,6 @@ /* Walk out chain. */ error = find_handler(IN, UDP, la, pip, &ad); - if (error == EHDNOF) - ; /* If UDP checksum is not zero, then adjust since destination port */ /* is being unaliased and destination address is being altered. */ @@ -803,8 +802,6 @@ /* Walk out chain. */ error = find_handler(OUT, UDP, la, pip, &ad); - if (error == EHDNOF) - ; /* If UDP checksum is not zero, adjust since source port is */ /* being aliased and source address is being altered */ @@ -870,8 +867,6 @@ /* Walk out chain. */ error = find_handler(IN, TCP, la, pip, &ad); - if (error == EHDNOF) - ; alias_address = GetAliasAddress(lnk); original_address = GetOriginalAddress(lnk); @@ -1031,8 +1026,6 @@ /* Walk out chain. */ error = find_handler(OUT, TCP, la, pip, &ad); - if (error == EHDNOF) - ; /* Adjust TCP checksum since source port is being aliased */ /* and source address is being altered */ @@ -1247,8 +1240,6 @@ /* Walk out chain. */ error = find_handler(IN, IP, la, pip, &ad); - if (error == EHDNOF) - ; if (error == OK) iresult = PKT_ALIAS_OK; else @@ -1374,8 +1365,6 @@ }; /* Walk out chain. */ error = find_handler(OUT, IP, la, pip, &ad); - if (error == EHDNOF) - ; if (error == OK) iresult = PKT_ALIAS_OK; else @@ -1505,8 +1494,6 @@ LibAliasRefreshModules(void) { char buf[256], conf[] = "/etc/libalias.conf"; FILE *fd; - struct dll *t; - struct proto_handler *p; int len; fd = fopen(conf, "r"); @@ -1584,6 +1571,7 @@ dlclose(t->handle); free(t); } + return (1); } #endif