From owner-freebsd-hackers@FreeBSD.ORG Fri Oct 8 16:14:42 2004 Return-Path: Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id AB3BF16A4CE; Fri, 8 Oct 2004 16:14:42 +0000 (GMT) Received: from ack.Berkeley.EDU (ack.Berkeley.EDU [128.32.206.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id 97EFC43D31; Fri, 8 Oct 2004 16:14:42 +0000 (GMT) (envelope-from mhunter@ack.Berkeley.EDU) Received: (from mhunter@localhost) by ack.Berkeley.EDU (8.11.3/8.11.3) id i98GEgf10525; Fri, 8 Oct 2004 09:14:42 -0700 (PDT) Date: Fri, 8 Oct 2004 09:14:42 -0700 From: Mike Hunter To: Harti Brandt Message-ID: <20041008161442.GA9862@ack.Berkeley.EDU> References: <20041005054213.GA11770@lesanti.hq.sinectis.com.ar> <20041005202816.GA14973@titan.klemm.apsfilter.org> <20041005205040.GH31397@lesanti.hq.sinectis.com.ar> <20041006060437.GA23364@titan.klemm.apsfilter.org> <20041006144220.GA29653@lesanti.hq.sinectis.com.ar> <416579E1.8050308@nuclearelephant.com> <20041008152905.GA3106@dan.emsphone.com> <20041008173138.Y14215@beagle.kn.op.dlr.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20041008173138.Y14215@beagle.kn.op.dlr.de> User-Agent: Mutt/1.5.6i cc: hackers@freebsd.org Subject: Re: please help with: warning: initialization makes integer from pointer X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Oct 2004 16:14:42 -0000 On Oct 08, "Harti Brandt" wrote: > On Fri, 8 Oct 2004, Dan Nelson wrote: > > Memset is actually not portable if the structure contains pointers because > it would initialize the pointers to 0 values not to 0 pointers. A 0 > pointer not necessarily has a 0 value. A pointer can be portably be > initialize to the 0-pointer only by assigning NULL (or 0) (or by assigning > another pointer that is alreay initialized). Sick! Are there actually systems out there that don't have "all-zero" NULL pointers? You have officially shattered my previously held beliefs about the sacredness of memset :( Mike