From owner-cvs-src-old@FreeBSD.ORG Thu Feb 19 16:30:17 2009 Return-Path: Delivered-To: cvs-src-old@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id C3F631065747 for ; Thu, 19 Feb 2009 16:30:17 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id AA8308FC14 for ; Thu, 19 Feb 2009 16:30:17 +0000 (UTC) (envelope-from imp@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.3/8.14.3) with ESMTP id n1JGUH8T078144 for ; Thu, 19 Feb 2009 16:30:17 GMT (envelope-from imp@repoman.freebsd.org) Received: (from svn2cvs@localhost) by repoman.freebsd.org (8.14.3/8.14.3/Submit) id n1JGUH7s078143 for cvs-src-old@freebsd.org; Thu, 19 Feb 2009 16:30:17 GMT (envelope-from imp@repoman.freebsd.org) Message-Id: <200902191630.n1JGUH7s078143@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: svn2cvs set sender to imp@repoman.freebsd.org using -f From: Warner Losh Date: Thu, 19 Feb 2009 16:30:11 +0000 (UTC) To: cvs-src-old@freebsd.org X-FreeBSD-CVS-Branch: HEAD Subject: cvs commit: src/usr.sbin/rtadvd rrenum.c X-BeenThere: cvs-src-old@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: **OBSOLETE** CVS commit messages for the src tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 19 Feb 2009 16:30:19 -0000 imp 2009-02-19 16:30:11 UTC FreeBSD src repository Modified files: usr.sbin/rtadvd rrenum.c Log: SVN rev 188820 on 2009-02-19 16:30:11Z by imp Properly convert bit value to a bit field. Before we were storing values like 0x80 or 0x40 into a uint8_t foo:1 bitfield. This would result in the bit always being 0. One of these caused a warning for overflow (one that was 0x80), but the other didn't. They were both wrong. This is why I hate code that mixes c struct bitfields and #defines. The rest of the fields accessed by the program should be audited. Revision Changes Path 1.10 +2 -2 src/usr.sbin/rtadvd/rrenum.c