Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 289366 - app-shells/bash-completion-1.1 missing backslash in main script and undefined function "have"
Summary: app-shells/bash-completion-1.1 missing backslash in main script and undefined...
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: Gentoo Shell Tools project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-10-16 18:41 UTC by Marcel Semancik
Modified: 2009-10-16 21:39 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marcel Semancik 2009-10-16 18:41:21 UTC
1.) Missing backslash in /etc/profile.d/bash-completion.sh when function _load_completions is called. Arguments are separated into lines and one of them is not ended with backslash.
This causes error like "bash: /etc/bash_completion.d/eselect: Permission denied" (or eselect is substituted with other enabled completion script) when starting bash.

2.) bash function "have" used in many scripts from /usr/share/bash-completion/ is undefined at the end of first executed script = /usr/share/bash-completion/.bash-completion
This causes errors "have: comand not found" when starting bash.


Reproducible: Always

Steps to Reproduce:
1. enable completion script with eselect that uses function "have". For instance "unrar".
2. run "bash"
3.

Actual Results:  
Print error output to just started shell.

Expected Results:  
No error output at all.
Comment 1 Andreas Proteus 2009-10-16 20:03:21 UTC
Well done!
Thanks for the tip.  
I was looking at this since yesterday and I couldn't find the cause of  it.
Comment 2 Jeremy Olexa (darkside) (RETIRED) archtester gentoo-dev Security 2009-10-16 21:39:31 UTC
Sorry, I really messed up that script. We are already on bash-completion-1.1-r2 which doesn't have that problem.