From owner-freebsd-ports@FreeBSD.ORG Sat May 17 06:52:23 2003 Return-Path: Delivered-To: freebsd-ports@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A794C37B401 for ; Sat, 17 May 2003 06:52:23 -0700 (PDT) Received: from falcon.midgard.homeip.net (h76n3fls20o913.telia.com [213.67.148.76]) by mx1.FreeBSD.org (Postfix) with SMTP id 06BA343F93 for ; Sat, 17 May 2003 06:52:21 -0700 (PDT) (envelope-from ertr1013@student.uu.se) Received: (qmail 90284 invoked by uid 1001); 17 May 2003 13:52:17 -0000 Date: Sat, 17 May 2003 15:52:17 +0200 From: Erik Trulsson To: Jonathan Belson Message-ID: <20030517135217.GA88537@falcon.midgard.homeip.net> Mail-Followup-To: Jonathan Belson , Kris Kennaway , ports@FreeBSD.org References: <3EC53C6C.1040904@witchspace.com> <20030517121908.GA67369@rot13.obsecurity.org> <3EC62CC2.6090209@witchspace.com> <20030517130549.GA44928@falcon.midgard.homeip.net> <3EC63B78.6010203@witchspace.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3EC63B78.6010203@witchspace.com> User-Agent: Mutt/1.5.4i cc: ports@FreeBSD.org cc: Kris Kennaway Subject: Re: FreeBSD Port: pornview-0.2.0.p.1 X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 17 May 2003 13:52:23 -0000 On Sat, May 17, 2003 at 02:39:04PM +0100, Jonathan Belson wrote: > Erik Trulsson wrote: > >That part of the structure is not the problem. The next part of this > >structure is the problem. > > > > gchar stdout[GTK_MPLAYER_BUF_SIZE]; > > gint stdout_size; > > gchar stderr[GTK_MPLAYER_BUF_SIZE]; > > gint stderr_size; > > True. > > >Not legitimate. The C standard itself says that stdin/stdout/stderr are > >supposed to be macros and therefore this behaviour is expected > > Interesting...do you have a reference for this? Section 7.9.1 of > the ANSI C spec says that stdin/stdout/stderr are expressions of > type 'pointer to FILE', I can't see anything that says they're > supposed to be macros. >From (a draft version of) the C99 standard: 7.19.1 [#1] The header declares three types, several macros, and many functions for performing input and output. .... [#3] The macros are [...] ... stderr stdin stdout which are expressions of type `pointer to FILE'' that point to the FILE objects associated, respectively, with the standard error, input, and output streams. Besides, the only way I can think of to have stdin/stdout/stderr available as expressions but not #define them is to have them as just plain variables, and if that was the only option available I am sure the standards committee would have written that. So even with the wording you give they *could* be macros, but might not necessarily have been. > > > The bug is in the application, not in FreeBSD, so, unfair or not, it > > isn't FreeBSD that should be changed. > > I don't remember anyone stating that FreeBSD should be changed... Not explicitly no, but if the pornview code was OK there wouldn't have been many other options left. -- Erik Trulsson ertr1013@student.uu.se