From owner-freebsd-current Tue Feb 18 12:55:34 2003 Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 253A337B401 for ; Tue, 18 Feb 2003 12:55:33 -0800 (PST) Received: from gw.nectar.cc (gw.nectar.cc [208.42.49.153]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9204E43F75 for ; Tue, 18 Feb 2003 12:55:31 -0800 (PST) (envelope-from nectar@celabo.org) Received: from madman.celabo.org (madman.celabo.org [10.0.1.111]) by gw.nectar.cc (Postfix) with ESMTP id 2DE2B3C; Tue, 18 Feb 2003 14:55:31 -0600 (CST) Received: by madman.celabo.org (Postfix, from userid 1001) id 84F7778C39; Tue, 18 Feb 2003 14:55:05 -0600 (CST) Date: Tue, 18 Feb 2003 14:55:05 -0600 From: "Jacques A. Vidrine" To: Dag-Erling Smorgrav Cc: Kris Kennaway , current@FreeBSD.org Subject: Re: memset prototype changed? Message-ID: <20030218205505.GA85519@madman.celabo.org> References: <20030218105240.GH92966@rot13.obsecurity.org> <20030218160442.GB81793@madman.celabo.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: X-Url: http://www.celabo.org/ User-Agent: Mutt/1.5.3i-ja.1 Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Tue, Feb 18, 2003 at 08:55:02PM +0100, Dag-Erling Smorgrav wrote: > "Jacques A. Vidrine" writes: > > On Tue, Feb 18, 2003 at 12:01:29PM +0100, Dag-Erling Smorgrav wrote: > > > The code that fails to compile is blatantly wrong: > > > > > > memset(schedule, 0, sizeof(schedule)); > > I wouldn't say `blantantly'. The expressions `schedule' and > > `&schedule' are equivalent when `schedule' is an array type. > > ...but Key_schedule is an opaque type, so it is not correct to assume > it's an array. You won't get much argument from me about that. Nonetheless, lots of code `knows' that it is `unsigned char[8]' (it _is_ DES, after all, where all the keys and operations are on 64 bits). Unfortunately, some of these practices were extended to the triple-DES interfaces as well... Cheers, -- Jacques A. Vidrine http://www.celabo.org/ NTT/Verio SME . FreeBSD UNIX . Heimdal Kerberos jvidrine@verio.net . nectar@FreeBSD.org . nectar@kth.se To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message