mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-10-29 05:40:23 -04:00
shell-completion: bash: Localize word variable
The word variables used in the _pactl and _pacmd functions are unlocalized. Thus, the variable appears in the user's environment when tab-completing with pactl or pacmd. This may clobber another variable of the same name, which is undesirable. Localize the word variable to fix this issue. Part-of: <https://gitlab.freedesktop.org/pulseaudio/pulseaudio/-/merge_requests/623>
This commit is contained in:
parent
2c7c0f0912
commit
53e3b53408
1 changed files with 2 additions and 2 deletions
|
|
@ -109,7 +109,7 @@ in_array() {
|
|||
}
|
||||
|
||||
_pactl() {
|
||||
local cur prev words cword preprev command
|
||||
local cur prev words cword preprev word command
|
||||
local comps
|
||||
local flags='-h --help --version -s --server= --client-name='
|
||||
local list_types='short sinks sources sink-inputs source-outputs cards
|
||||
|
|
@ -255,7 +255,7 @@ _pactl() {
|
|||
complete -F _pactl pactl
|
||||
|
||||
_pacmd() {
|
||||
local cur prev words cword preprev command
|
||||
local cur prev words cword preprev word command
|
||||
local comps
|
||||
local flags='-h --help --version'
|
||||
local commands=(exit help list-modules list-cards list-sinks list-sources list-clients
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue