From owner-freebsd-questions Wed Jan 19 8:11:37 2000 Delivered-To: freebsd-questions@freebsd.org Received: from cs.tamu.edu (clavin.cs.tamu.edu [128.194.130.106]) by hub.freebsd.org (Postfix) with ESMTP id D5F1E14DC8 for ; Wed, 19 Jan 2000 08:11:35 -0800 (PST) (envelope-from sks1974@cs.tamu.edu) Received: from dilbert.cs.tamu.edu (IDENT:2708@dilbert [128.194.133.100]) by cs.tamu.edu (8.9.3/8.9.3) with ESMTP id KAA08112 for ; Wed, 19 Jan 2000 10:11:32 -0600 (CST) Received: from localhost (sks1974@localhost) by dilbert.cs.tamu.edu (8.9.3/8.9.3) with ESMTP id KAA00666 for ; Wed, 19 Jan 2000 10:11:32 -0600 (CST) X-Authentication-Warning: dilbert.cs.tamu.edu: sks1974 owned process doing -bs Date: Wed, 19 Jan 2000 10:11:32 -0600 (CST) From: Suresh Kumar Satapati X-Sender: sks1974@dilbert To: freebsd-questions@freebsd.org Subject: C question Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I have a C question. I have a routing message structure .. static struct srtmsg {...}rtmsg; declared as above. Now i have to write a portion of this structure to a routing socket (PF_ROUTE) using a 'write' call. My call looks as below: write(socketfd, (char*)&rtmsg, len) where 'len' is a valid integer. The value of 'len' is less than sizeof(struct srtmsg). This call fails and gives a Page Fault. Please let me know if there is a better way to do this. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message