bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

A possible bug on autocompletion after setting FUNCNEST level


From: Valentin Bajrami
Subject: A possible bug on autocompletion after setting FUNCNEST level
Date: Mon, 8 Oct 2018 14:06:39 +0200

This is some kind of a follow up on "Segfault on recursive trap/kill"
reported by Mike Grewitz.

After setting FUNCNEST and the listing a file or using 'vi filname[TAB]'  a
bug is triggered.

This is how I could reproduce this:

f3d0r4:~/FOO# FUNCNEST=4

f3d0r4:~/FOO# ls
procps-ng-3.3.12-3.fc28.src.rpm
procps-ng-3.3.12-pmap-all-lines-twice.patch  procps-ng-3.3.12.tar.xz
procps-ng-3.3.14-CVE-2018-1124.patch  procps-ng.spec  README.md  README.top

f3d0r4:~/FOO# vi pr-bash: __reassemble_comp_words_by_ref: maximum function
nesting level exceeded (4)

f3d0r4:~/FOO# echo "$BASH_VERSION"
4.4.23(1)-release

f3d0r4:~/FOO# ls pr-bash: __reassemble_comp_words_by_ref: maximum function
nesting level exceeded (4)

f3d0r4:~/FOO# set -x
++ printf '\033]0;address@hidden:%s\007' root f3d0r4 '~/FOO'
f3d0r4:~/FOO# ls pr+ local cur prev words cword split
+ _init_completion -s
+ local exclude= flag outx errx inx OPTIND=1
+ getopts n:e:o:i:s flag -s
+ case $flag in
+ split=false
+ exclude+==
+ getopts n:e:o:i:s flag -s
+ COMPREPLY=()
+ local 'redir=@(?([0-9])<|?([0-9&])>?(>)|>&)'
+ _get_comp_words_by_ref -n '=<>&' cur prev words cword
+ local exclude flag i OPTIND=1
+ words=()
+ local cur cword words
+ upargs=()
+ upvars=()
+ local upargs upvars vcur vcword vprev vwords
+ getopts c:i:n:p:w: flag -n '=<>&' cur prev words cword
+ case $flag in
+ exclude='=<>&'
+ getopts c:i:n:p:w: flag -n '=<>&' cur prev words cword
+ [[ 6 -ge 3 ]]
+ case ${!OPTIND} in
+ vcur=cur
+ let 'OPTIND += 1'
+ [[ 6 -ge 4 ]]
+ case ${!OPTIND} in
+ vprev=prev
+ let 'OPTIND += 1'
+ [[ 6 -ge 5 ]]
+ case ${!OPTIND} in
+ vwords=words
+ let 'OPTIND += 1'
+ [[ 6 -ge 6 ]]
+ case ${!OPTIND} in
+ vcword=cword
+ let 'OPTIND += 1'
+ [[ 6 -ge 7 ]]
+ __get_cword_at_cursor_by_ref '=<>&' words cword cur
+ words=()
+ local cword words
+ __reassemble_comp_words_by_ref '=<>&' words cword
-bash: __reassemble_comp_words_by_ref: maximum function nesting level
exceeded (4)
++ printf '\033]0;address@hidden:%s\007' root f3d0r4 '~/FOO'

Especially the following line:  bash: __reassemble_comp_words_by_ref:
maximum function nesting level exceeded (4)

-- 
Met vriendelijke groet,

Valentin Bajrami


reply via email to

[Prev in Thread] Current Thread [Next in Thread]