lkml.org 
[lkml]   [2004]   [Feb]   [22]   [last100]   RSS Feed
Views: [more markup]  [less markup]  [headers]  [forward] 
 
Messages in this thread
/
DateSun, 22 Feb 2004 02:09:11 -0800
FromPaul Jackson <>
SubjectRe: [PATCH] Linux 2.6: shebang handling in fs/binfmt_script.c
In addition to the incompatible changes you note:
  1) "#! cmd x y" to pass single arg "x y" with embedded space broken
  2) Use of '\' char changed
  3) Handling of long line changed
doesn't this also
  4) risk breaking shells that look to argv[2] for the name of the
    shell script file for error messages?  This argument
    has moved out to argv[argc-1], for some value of argc.

I'll wager you have to make a better case for this than simply:

    As I'm really missing this feature in Linux and changing this
    would not break any (unless ...

before the above incompatibilities in a critical piece of code are
overcome with the compelling need to change these details.

Perhaps you can handle any such special argument specification by
wrapping the user level command, as in:

Instead of:

    #!/usr/bin/awk -F \t -f
    ... my awk code ...

rather do:

    #!myawk
    ... my awk code ...

where myawk is a compiled program that essentially does

    /usr/bin/awk -F '\t' -f argv[2]

-- 
                          I won't rest till it's the best ...
                          Programmer, Linux Scalability
                          Paul Jackson <pj@sgi.com> 1.650.933.1373
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 13:01    [from the cache]
©2003-2008