Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: 8-bit patch for zle_tricky.c



In your mail, you said:
> >I do not think so.  Neither bash nor ksh93 does this.  Look:
> >
> >% ksh
> >$ count () { echo $# ; }
> >$ IFS=/
> >$ count as/df/gh
> >1
> >
> >SH_WORD_SPLIT only changes the result of substitutions.
> 
> Hmm.  ksh doesn't field split there, but sh does.  I think we should
> eventually have an option to emulate this, but it's not essential.

I think that bash intentionally avoids word-splitting in these cases, to
close the infamous IFS-security hole in sh, for setuid scripts/programs.

-- 
hniksic@xxxxxxx              |  Student of electrical engineering
hniksic@xxxxxxxxxxxxx        |  University of Zagreb, Croatia
------------------------------------------------------------------
`VI' - An editor used by those heretics that don't subscribe to
       the Emacs religion.




Messages sorted by: Reverse Date, Date, Thread, Author