Path: csiph.com!goblin2!goblin1!goblin.stu.neva.ru!usenet.stanford.edu!not-for-mail From: L A Walsh Newsgroups: gnu.bash.bug Subject: Re: shebang-less script execution not resetting some options Date: Wed, 02 Oct 2019 03:11:18 -0700 Lines: 25 Approved: bug-bash@gnu.org Message-ID: References: <5D9334F8.3090503@tlinx.org> <20191001124135.GJ28751@eeg.ccf.org> <5D9477C6.2000002@tlinx.org> NNTP-Posting-Host: lists.gnu.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-Trace: usenet.stanford.edu 1570011087 27015 209.51.188.17 (2 Oct 2019 10:11:27 GMT) X-Complaints-To: action@cs.stanford.edu To: bug-bash@gnu.org Envelope-to: bug-bash@gnu.org User-Agent: Thunderbird In-Reply-To: <20191001124135.GJ28751@eeg.ccf.org> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x (no timestamps) [generic] [fuzzy] X-Received-From: 173.164.175.65 X-BeenThere: bug-bash@gnu.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Bug reports for the GNU Bourne Again SHell List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Mailman-Original-Message-ID: <5D9477C6.2000002@tlinx.org> X-Mailman-Original-References: <5D9334F8.3090503@tlinx.org> <20191001124135.GJ28751@eeg.ccf.org> Xref: csiph.com gnu.bash.bug:15450 On 2019/10/01 05:41, Greg Wooledge wrote: > On Tue, Oct 01, 2019 at 04:14:00AM -0700, L A Walsh wrote: > >> On 2019/09/30 14:39, Grisha Levit wrote: >> >>> A few of the recently-added shopt options aren't getting reset when >>> running a shebang-less script, this should fix it up: >>> >>> >> Suppose the shebang-less script is being run by an earlier version >> of bash. Won't the new patch radically change the behavior of of >> such programs? >> > > Bash allows a child of itself (a subshell) to read the commands. > GNU find -exec uses /bin/sh to run it. > zsh and csh both use /bin/sh to run it, I think. > ---- So if a user has 'rbash' in /etc/passwd, they might get a real shell because various programs ignore what /etc/passwd says? Um....I suppose no one cares for one reason or another.