Bug 104491
Summary: | bashrc incorrect check for login shell | ||||||
---|---|---|---|---|---|---|---|
Product: | [Retired] Red Hat Linux | Reporter: | Steve Stavropoulos <steve> | ||||
Component: | setup | Assignee: | Bill Nottingham <notting> | ||||
Status: | CLOSED RAWHIDE | QA Contact: | David Lawrence <dkl> | ||||
Severity: | medium | Docs Contact: | |||||
Priority: | medium | ||||||
Version: | 9 | CC: | rvokal | ||||
Target Milestone: | --- | ||||||
Target Release: | --- | ||||||
Hardware: | All | ||||||
OS: | Linux | ||||||
Whiteboard: | |||||||
Fixed In Version: | 2.5.34-1 | Doc Type: | Bug Fix | ||||
Doc Text: | Story Points: | --- | |||||
Clone Of: | Environment: | ||||||
Last Closed: | 2004-09-23 05:20:37 UTC | Type: | --- | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Steve Stavropoulos
2003-09-16 12:55:16 UTC
An improvement over the previous patch would be to replace the if line with: if ! shopt -q login_shell; then # We're not a login shell That way no cut is needed and we have a cleaner solution. I would recommend that you use the $- variable to determine if the shell is interactive. This will save in having to execute progs and form a pipe. See the my patch for details. Created attachment 98128 [details] attachment removed. Comment #1 has a better fix. My patch works for RH9, Fedora, and RHEL3. I'll withdraw my comments #2, #3 and the attachment. I see that the sub-submitter is looking for login shell, not interactive shells. The use of if ! shopt -q login_shell; then ... is just as good. Therefore I recommend the patch: https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=104491#c1 as suggested in comment #1. Comment on attachment 98128 [details] attachment removed. Comment #1 has a better fix. Comment on attachment 98128 [details] attachment removed. Comment #1 has a better fix. Patch removed. Added in 2.5.34-1. This seems to break things: see bug #165873. |