sh-setup: protect from exported IFS
commit785063e02bb249ef3a39db88575fe626b310d4a7
authorJunio C Hamano <gitster@pobox.com>
Wed, 8 Aug 2012 19:08:17 +0000 (8 12:08 -0700)
committerJunio C Hamano <gitster@pobox.com>
Wed, 8 Aug 2012 21:36:33 +0000 (8 14:36 -0700)
treeb23673aef74184f0413ee71044df6034ec08aab6
parentd0f1ea6003d97e63110fa7d50bb07f546a909b6e
sh-setup: protect from exported IFS

Many scripted Porcelains rely on being able to split words at the
default $IFS characters, i.e. SP, HT and LF.  If the user exports a
non-default IFS to the environment, what they read from plumbing
commands such as ls-files that use HT to delimit fields may not be
split in the way we expect.

Protect outselves by resetting it, just like we do so against CDPATH
exported to the environment.

Noticed by Andrew Dranse <adranse@oanda.com>.

Signed-off-by: Junio C Hamano <gitster@pobox.com>
git-sh-setup.sh