Return-Path: Delivered-To: apmail-apr-cvs-archive@apr.apache.org Received: (qmail 22005 invoked by uid 500); 15 Mar 2001 21:55:00 -0000 Mailing-List: contact cvs-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Reply-To: dev@apr.apache.org Delivered-To: mailing list cvs@apr.apache.org Received: (qmail 21970 invoked by uid 1121); 15 Mar 2001 21:54:59 -0000 Date: 15 Mar 2001 21:54:59 -0000 Message-ID: <20010315215459.21969.qmail@apache.org> From: trawick@apache.org To: apr-cvs@apache.org Subject: cvs commit: apr/network_io/unix sa_common.c trawick 01/03/15 13:54:59 Modified: network_io/unix sa_common.c Log: Get rid of a warning about using maxbits uninitialized (the compiler didn't realize we'd already checked the family) Revision Changes Path 1.32 +2 -5 apr/network_io/unix/sa_common.c Index: sa_common.c =================================================================== RCS file: /home/cvs/apr/network_io/unix/sa_common.c,v retrieving revision 1.31 retrieving revision 1.32 diff -u -r1.31 -r1.32 --- sa_common.c 2001/03/15 19:43:46 1.31 +++ sa_common.c 2001/03/15 21:54:59 1.32 @@ -634,7 +634,7 @@ { apr_status_t rv; char *endptr; - long bits, maxbits; + long bits, maxbits = 32; /* filter out stuff which doesn't look remotely like an IP address; this helps * callers like mod_access which have a syntax allowing hostname or IP address; @@ -656,11 +656,8 @@ } if (mask_or_numbits) { - if ((*ipsub)->family == AF_INET) { - maxbits = 32; - } #if APR_HAVE_IPV6 - else { + if ((*ipsub)->family == AF_INET6) { maxbits = 128; } #endif