From avatar@rift.ath.cx  Sat Jan 25 03:28:29 2003
Return-Path: <avatar@rift.ath.cx>
Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125])
	by hub.freebsd.org (Postfix) with ESMTP id D6DBA37B401
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 25 Jan 2003 03:28:29 -0800 (PST)
Received: from rift.ath.cx (h58n2fls32o836.telia.com [217.208.105.58])
	by mx1.FreeBSD.org (Postfix) with ESMTP id D06B743EB2
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 25 Jan 2003 03:28:24 -0800 (PST)
	(envelope-from avatar@rift.ath.cx)
Received: from rift.ath.cx (localhost [127.0.0.1])
	by rift.ath.cx (8.12.6/8.12.6) with ESMTP id h0PBSHn5071502
	for <FreeBSD-gnats-submit@freebsd.org>; Sat, 25 Jan 2003 12:28:17 +0100 (CET)
	(envelope-from avatar@rift.ath.cx)
Received: (from avatar@localhost)
	by rift.ath.cx (8.12.6/8.12.6/Submit) id h0PBSG6P071501;
	Sat, 25 Jan 2003 12:28:16 +0100 (CET)
Message-Id: <200301251128.h0PBSG6P071501@rift.ath.cx>
Date: Sat, 25 Jan 2003 12:28:16 +0100 (CET)
From: David Holm <david@realityrift.com>
Reply-To: David Holm <david@realityrift.com>
To: FreeBSD-gnats-submit@freebsd.org
Cc:
Subject: Possible /usr/include/sys/uio.h problem
X-Send-Pr-Version: 3.113
X-GNATS-Notify:

>Number:         47459
>Category:       kern
>Synopsis:       Possible /usr/include/sys/uio.h problem
>Confidential:   no
>Severity:       non-critical
>Priority:       low
>Responsible:    freebsd-bugs
>State:          closed
>Quarter:        
>Keywords:       
>Date-Required:  
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sat Jan 25 03:30:02 PST 2003
>Closed-Date:    Thu Feb 06 14:51:55 PST 2003
>Last-Modified:  Thu Feb 06 14:51:55 PST 2003
>Originator:     David Holm
>Release:        FreeBSD 4.7-STABLE i386
>Organization:
>Environment:
System: FreeBSD rift.ath.cx 4.7-STABLE FreeBSD 4.7-STABLE #0: Sat Jan 18 13:12:30 CET 2003 avatar@rift.ath.cx:/usr/src/sys/compile/MYKERNEL i386


	
>Description:
	
On line 86 sys/uio.h includes sys/cdefs.h, I assume it is to get "ssize_t"? Since when I compile ORBit-gt that uses sys/uio.h it fails due to ssize_t not being defined, and it isn't in sys/cdefs.h
>How-To-Repeat:
	
>Fix:

	


>Release-Note:
>Audit-Trail:

From: Peter Pentchev <roam@ringlet.net>
To: David Holm <david@realityrift.com>
Cc: bug-followup@FreeBSD.org
Subject: Re: kern/47459: Possible /usr/include/sys/uio.h problem
Date: Sat, 25 Jan 2003 14:24:08 +0200

 On Sat, Jan 25, 2003 at 12:28:16PM +0100, David Holm wrote:
 > 
 > >Number:         47459
 > >Category:       kern
 > >Synopsis:       Possible /usr/include/sys/uio.h problem
 > >Originator:     David Holm
 > >Release:        FreeBSD 4.7-STABLE i386
 > >Description:
 > 	
 
 > On line 86 sys/uio.h includes sys/cdefs.h, I assume it is to get
 > "ssize_t"?
 
 Not really; the inclusion of sys/cdefs.h is made to get the
 __BEGIN_DECLS and __END_DECLS definitions.
 
 > Since when I compile ORBit-gt that uses sys/uio.h it fails
 > due to ssize_t not being defined, and it isn't in sys/cdefs.h
 
 This looks like a bug in your application (ORBit-gt) - ssize_t is
 defined in sys/types.h, and the manual pages of the functions declared
 in sys/uio.h (readv(2), writev(2)) specify that sys/types.h must be
 included before sys/uio.h.
 
 G'luck,
 Peter
 
 -- 
 Peter Pentchev	roam@ringlet.net	roam@FreeBSD.org
 PGP key:	http://people.FreeBSD.org/~roam/roam.key.asc
 Key fingerprint	FDBA FD79 C26F 3C51 C95E  DF9E ED18 B68D 1619 4553
 If this sentence didn't exist, somebody would have invented it.
State-Changed-From-To: open->closed 
State-Changed-By: mike 
State-Changed-When: Thu Feb 6 14:47:14 PST 2003 
State-Changed-Why:  

Your application is assuming <sys/uio.h> typedefs ssize_t.  Since 
FreeBSD 4.x doesn't support POSIX.1-2001, this assumption fails.  A 
workaround is to include <sys/types.h> prior to <sys/uio.h> or use 
FreeBSD 5.0-RELEASE (or newer) where this problem has been fixed. 

http://www.freebsd.org/cgi/query-pr.cgi?pr=47459 
>Unformatted:
