1
0
Fork 0
mirror of git://git.code.sf.net/p/zsh/code synced 2025-10-26 04:30:27 +01:00

30020: prevent prompt_opts and zle_highlight from leaking out of

prompt_preview_theme
This commit is contained in:
Bart Schaefer 2011-12-13 17:43:55 +00:00
parent 3f98949ca8
commit c33f3b0747

View file

@ -180,7 +180,8 @@ prompt_preview_theme () {
emulate -L zsh emulate -L zsh
local -a psv; psv=($psvar); local -a +h psvar; psvar=($psv) # Ick local -a psv; psv=($psvar); local -a +h psvar; psvar=($psv) # Ick
local +h PS1=$PS1 PS2=$PS2 PS3=$PS3 PS4=$PS4 RPS1=$RPS1 local +h PS1=$PS1 PS2=$PS2 PS3=$PS3 PS4=$PS4 RPS1=$RPS1
local precmd_functions preexec_functions local precmd_functions preexec_functions prompt_opts
local -aLl +h zle_highlight
print -n "$1 theme" print -n "$1 theme"
(( $#* > 1 )) && print -n " with parameters \`$*[2,-1]'" (( $#* > 1 )) && print -n " with parameters \`$*[2,-1]'"