bug-global
[Top][All Lists]
Advanced

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

htags fails with "Negative exec line limit" if the environment is large


From: Peter Maydell
Subject: htags fails with "Negative exec line limit" if the environment is large
Date: Mon, 8 Jan 2024 12:56:21 +0000

Hi; I'd like to report a bug in 'htags': it fails with an obscure
error message if the environment happens to be large. Here's a
repro case:

$ mkdir htags-bug
$ cd htags-bug/
$ cat >hello.c
#include <stdio.h>

int main(void) {
    printf("hello world\n");
    return 0;
}
$ gtags
$ htags -anT
$ BIGVAR=$(perl -e 'print "x" x 100000') htags -anT
htags: Negative exec line limit = -80391

As you can see, htags works normally with a small environment, but
if there happens to be an environment variable whose value is large
then it fails.

We ran into this with QEMU, because it happens that the GitLab CI
system puts the text of the git commit message into an environment
variable. So our CI job that runs 'htags' fell over if the commit
being tested had a large commit message...
(The QEMU bug about this is
https://gitlab.com/qemu-project/qemu/-/issues/2080 -- we'll work
around this by clearing that environment variable before running
htags, but I wanted to report it to you upstream as well.)

I've tested this with "htags (GNU Global) 6.6.11"; the bug
is also present in earlier versions, such as those distributed
in Debian and Ubuntu.

thanks
-- Peter Maydell



reply via email to

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