From owner-freebsd-questions Sat Aug 26 2:49: 6 2000 Delivered-To: freebsd-questions@freebsd.org Received: from scientia.demon.co.uk (scientia.demon.co.uk [212.228.14.13]) by hub.freebsd.org (Postfix) with ESMTP id 37B8537B424 for ; Sat, 26 Aug 2000 02:49:01 -0700 (PDT) Received: from strontium.scientia.demon.co.uk ([192.168.91.36] ident=root) by scientia.demon.co.uk with esmtp (Exim 3.16 #1) id 13ScZl-000Na1-00; Sat, 26 Aug 2000 10:48:33 +0100 Received: (from ben@localhost) by strontium.scientia.demon.co.uk (8.9.3/8.9.3) id KAA93133; Sat, 26 Aug 2000 10:48:33 +0100 (BST) (envelope-from ben) Date: Sat, 26 Aug 2000 10:48:33 +0100 From: Ben Smithurst To: Ed Alley Cc: freebsd-questions@freebsd.org Subject: Re: sockaddr differences Message-ID: <20000826104833.A46871@strontium.scientia.demon.co.uk> References: <200008260101.SAA02730@jordan.llnl.gov> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2i In-Reply-To: <200008260101.SAA02730@jordan.llnl.gov> Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Ed Alley wrote: > This difference introduced some subtle bugs; I really began to > think that I had forgotten how to program. What sort of bugs? It sounds like you've been doing something rather strange in your code. > First Question: > Why is FreeBSD different? I don't know, but the answer is probably "historical reasons". > Second Question: > Does anyone know of a simple way that I can > program around this without putting in a > lot of ifdefs in my programs? uh... Why do you need to? Just don't touch sun_len and you won't get problems with it not existing on other systems. I just bzero the whole structure before initializing the fields which matter. -- Ben Smithurst / ben@FreeBSD.org / PGP: 0x99392F7D To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message