Re: Bug in #! processing
From: Sławek Żak (szak_at_era.pl)
Date: 09/30/04
- Previous message: Oliver Lehmann: "Re: 5.3-RELEASE TODO"
- Next in thread: Garrett Wollman: "Re: Bug in #! processing"
- Maybe reply: Garrett Wollman: "Re: Bug in #! processing"
- Reply: Brandon S. Allbery KF8NH: "Re: Bug in #! processing"
- Maybe reply: Pawel Jakub Dawidek: "Re: Bug in #! processing"
- Maybe reply: Scot W. Hetzel: "Re: Bug in #! processing"
- Maybe reply: David G. Lawrence: "Re: Bug in #! processing"
- Maybe reply: Roman Neuhauser: "Re: Bug in #! processing"
- Maybe reply: Bjoern Koenig: "Re: Bug in #! processing"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
To: "David G. Lawrence" <dg@dglawrence.com> Date: Thu, 30 Sep 2004 15:16:21 +0200
"David G. Lawrence" <dg@dglawrence.com> writes:
>> What circular reference? Could you elaborate? The algorithm goes like this:
>>
>> 1. skip all space till #!
>
> The #! is required to be in the first two bytes of the file, so there
> can't be any spaces before it.
Oh. Thus in following script:
thirst<zaks>(1950)% cat tst.sh
#!/bin/no-such-file
ps -lp $$
Which generates following output.
thirst<zaks>(1949)% ./tst.sh /tmp
UID PID PPID CPU PRI NI VSZ RSS MWCHAN STAT TT TIME COMMAND
1001 31645 31278 0 8 0 1636 1024 wait S+ p5 0:00.00 sh ./tst.sh
the interpreter is assumed to be /bin/sh. That's fine with me.
> I wrote the code you guys are talking about, although I had nothing to do
> with the commit in rev 1.21. I don't have an opinion on that other than
> it's been this way in FreeBSD for a long time and I share Ceri's concern
> that changing it will affect some people.
By no means I wish to force anyone to fix their scripts for 5.3
release. Period. I would only like to use Allegro CL in scripts, which
unfortunately considers -#! valid in argument list and acts accordingly on
all platforms besides FreeBSD. Some (in)compatibility shim would be
great. Please! :)
/S
-- Sławek Żak : UNIX Systems Administrator : PTC Sp. zoo _______________________________________________ freebsd-current@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-current To unsubscribe, send any mail to "freebsd-current-unsubscribe@freebsd.org"
- Previous message: Oliver Lehmann: "Re: 5.3-RELEASE TODO"
- Next in thread: Garrett Wollman: "Re: Bug in #! processing"
- Maybe reply: Garrett Wollman: "Re: Bug in #! processing"
- Reply: Brandon S. Allbery KF8NH: "Re: Bug in #! processing"
- Maybe reply: Pawel Jakub Dawidek: "Re: Bug in #! processing"
- Maybe reply: Scot W. Hetzel: "Re: Bug in #! processing"
- Maybe reply: David G. Lawrence: "Re: Bug in #! processing"
- Maybe reply: Roman Neuhauser: "Re: Bug in #! processing"
- Maybe reply: Bjoern Koenig: "Re: Bug in #! processing"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|