From owner-freebsd-bugs Tue Feb 15 0:55:55 2000 Delivered-To: freebsd-bugs@freebsd.org Received: from gilgamesch.bik-gmbh.de (gilgamesch.bik-gmbh.de [194.233.237.194]) by builder.freebsd.org (Postfix) with ESMTP id AD48241EC for ; Tue, 15 Feb 2000 00:55:51 -0800 (PST) Received: (from cracauer@localhost) by gilgamesch.bik-gmbh.de (8.9.3/8.7.3) id JAA94952; Tue, 15 Feb 2000 09:56:06 +0100 (MET) Date: Tue, 15 Feb 2000 09:56:06 +0100 From: Martin Cracauer To: Shawn Halpenny Cc: freebsd-bugs@FreeBSD.ORG, ryand@amazon.com Subject: Re: [PATCH] Re: bin/16393: /bin/sh doesn't strip comments on shebang line Message-ID: <20000215095606.A94896@cons.org> References: <200002102120.NAA69877@freefall.freebsd.org> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="n8g4imXOkfNTN/H1" X-Mailer: Mutt 1.0.1i In-Reply-To: <200002102120.NAA69877@freefall.freebsd.org>; from malachai@iname.com on Thu, Feb 10, 2000 at 01:20:02PM -0800 Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org --n8g4imXOkfNTN/H1 Content-Type: text/plain; charset=us-ascii This has been fixed in version 1.21. Since there is no standard that specifies how the #! - line should work, could the both of you please give the current version a try if it supports the cases you need? Either get the neest -current or try the appended patch. Thanks Martin -- %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% Martin Cracauer http://www.cons.org/cracauer/ BSD User Group Hamburg, Germany http://www.bsdhh.org/ --n8g4imXOkfNTN/H1 Content-Type: text/plain; charset=us-ascii Content-Disposition: attachment; filename=l Index: kern/imgact_shell.c =================================================================== RCS file: /home/CVS-FreeBSD/src/sys/kern/imgact_shell.c,v retrieving revision 1.20 diff -c -r1.20 imgact_shell.c *** kern/imgact_shell.c 1999/08/28 00:46:10 1.20 --- kern/imgact_shell.c 2000/02/11 16:30:38 *************** *** 76,82 **** /* * Find end of line; return if the line > MAXSHELLCMDLEN long. */ ! for (ihp = &image_header[2]; *ihp != '\n'; ++ihp) { if (ihp >= &image_header[MAXSHELLCMDLEN]) return(ENOEXEC); } --- 76,82 ---- /* * Find end of line; return if the line > MAXSHELLCMDLEN long. */ ! for (ihp = &image_header[2]; *ihp != '\n' && *ihp != '#'; ++ihp) { if (ihp >= &image_header[MAXSHELLCMDLEN]) return(ENOEXEC); } --n8g4imXOkfNTN/H1-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message