[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[BUG] global abnormally exits when a token contains '@'
From: |
Yoshitaro Makise |
Subject: |
[BUG] global abnormally exits when a token contains '@' |
Date: |
Thu, 27 Nov 2014 00:50:37 +0900 |
Hi,
I found a bug in the global command.
------------------------------
$ cat sample.sh
echo $@
echo $@
$ GTAGSPYGMENTSOPTS= gtags --gtagslabel=pygments
$ gtags -d GRTAGS
__.COMPACT __.COMPACT
__.COMPLINE __.COMPLINE
__.COMPNAME __.COMPNAME
__.VERSION __.VERSION 6
$@ 2 @n 1-1
echo 2 @n 1-1
$ global -xs '.*'
$@ 1 sample.sh echo $@
global: Abbrev character must be a lower alphabetic character. ()
------------------------------
global exits with the message "Abbrev character must be a lower
alphabetic character. ()".
The cause is that in put_compact_format() uncompress() is applied
repeatedly when a tagline has two or more line numbers.
e.g.
uncompress("@n", "$@"); // 1st iteration
uncompress("$@", "$@"); // 2nd iteration -> error
The attached patch ensures uncompress() is called only once.
Thanks,
output.c.diff
Description: Text document
- [BUG] global abnormally exits when a token contains '@',
Yoshitaro Makise <=