NetBSD Problem Report #44619

From gregoire.sutre@labri.fr  Tue Feb 22 16:26:50 2011
Return-Path: <gregoire.sutre@labri.fr>
Received: from mail.netbsd.org (mail.netbsd.org [204.152.190.11])
	by www.NetBSD.org (Postfix) with ESMTP id 395FB63B880
	for <gnats-bugs@gnats.NetBSD.org>; Tue, 22 Feb 2011 16:26:50 +0000 (UTC)
Message-Id: <20110222162642.285A3120DE@niagara.localdomain>
Date: Tue, 22 Feb 2011 17:26:41 +0100 (CET)
From: gregoire.sutre@gmail.com
Reply-To: gregoire.sutre@gmail.com
To: gnats-bugs@gnats.NetBSD.org
Subject: Missing substitution in /etc/X11/xinit/xinitrc
X-Send-Pr-Version: 3.95

>Number:         44619
>Category:       xsrc
>Synopsis:       Missing substitution in /etc/X11/xinit/xinitrc
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    xsrc-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Feb 22 16:30:00 +0000 2011
>Closed-Date:    Sun Mar 06 01:11:16 +0000 2011
>Last-Modified:  Sun Mar 06 01:11:16 +0000 2011
>Originator:     Gregoire Sutre
>Release:        NetBSD 5.99.46
>Organization:
>Environment:
System: NetBSD niagara 5.99.46 NetBSD 5.99.46 (GENERIC) #0: Mon Feb 21 16:22:14 CET 2011 sutre@niagara:/usr/build/usr/src/sys/arch/i386/compile/GENERIC i386
Architecture: i386
Machine: i386
>Description:
The file ./etc/X11/xinit/xinitrc included in xetc.tgz contains:

if [ -d /etc/X11/xinit/xinitrc.d ] ; then
        for f in /etc/X11/xinit/xinitrc.dXSLASHGLOB.sh ; do

According to the file cpprules.in of the xinit distribution,
the `XSLASHGLOB' part should be replaced by `/*'.

>How-To-Repeat:
>Fix:

>Release-Note:

>Audit-Trail:
From: David Holland <dholland-bugs@netbsd.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: xsrc/44619: Missing substitution in /etc/X11/xinit/xinitrc
Date: Mon, 28 Feb 2011 07:04:58 +0000

 On Tue, Feb 22, 2011 at 04:30:01PM +0000, gregoire.sutre@gmail.com wrote:
  > According to the file cpprules.in of the xinit distribution,
  > the `XSLASHGLOB' part should be replaced by `/*'.

 I think the best way to deal with this is not to try to wedge in the
 extra SED_MAGIC for producing '/*' but to change the glob in the
 distributed xinitrc template to '/?*', which should be equivalent and
 avoids confusing cpp.

 This should be sent upstream, but it's not clear from anything in the
 xinit distribution how to do that.

 Index: xinitrc.cpp
 ===================================================================
 RCS file: /cvsroot/xsrc/external/mit/xinit/dist/xinitrc.cpp,v
 retrieving revision 1.1.1.3
 diff -u -p -r1.1.1.3 xinitrc.cpp
 --- xinitrc.cpp	21 Nov 2010 03:47:48 -0000	1.1.1.3
 +++ xinitrc.cpp	28 Feb 2011 07:03:31 -0000
 @@ -84,8 +84,9 @@ fi
  XCOMM This is the fallback case if nothing else is executed above
  #endif /* !defined(__SCO__)  && !defined(__UNIXWARE__) */

 +XCOMM do not use slash-star in the glob; slash-questionmark-star is equivalent
  if [ -d XINITDIR/xinitrc.d ] ; then
 -	for f in XINITDIR/xinitrc.dXSLASHGLOB.sh ; do
 +	for f in XINITDIR/xinitrc.d/?*.sh ; do
  		[ -x "$f" ] && . "$f"
  	done
  	unset f


 -- 
 David A. Holland
 dholland@netbsd.org

From: "David A. Holland" <dholland@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/44619 CVS commit: xsrc/external/mit/xinit/dist
Date: Sun, 6 Mar 2011 01:05:51 +0000

 Module Name:	xsrc
 Committed By:	dholland
 Date:		Sun Mar  6 01:05:51 UTC 2011

 Modified Files:
 	xsrc/external/mit/xinit/dist: xinitrc.cpp

 Log Message:
 Use xinitrc.d/?*.sh as the matching pattern instead of needing a
 fragile sed substitution XSLASHGLOB to produce xinitrc.d/*.sh. (If
 that were used literally the slash-star would confuse cpp.)

 Fixes PR 44619. Patch has been sent upstream.


 To generate a diff of this commit:
 cvs rdiff -u -r1.1.1.3 -r1.2 xsrc/external/mit/xinit/dist/xinitrc.cpp

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: open->closed
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sun, 06 Mar 2011 01:11:16 +0000
State-Changed-Why:
fixed, thanks


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.