So, I set external_to_internal_register to 0 and the crash went away.
Patch included here:
--- xemacs-21.4.16/lib-src/etags.c 2004-06-24 00:02:29.000000000 -0400
+++ xemacs-21.4.16/lib-src/etags.c-works 2004-12-16 15:44:56.109304000 -0500
@@ -5171,6 +5171,7 @@
patbuf->fastmap = NULL;
patbuf->buffer = NULL;
patbuf->allocated = 0;
+ patbuf->external_to_internal_register = 0;
err = re_compile_pattern (regexp_pattern, strlen (regexp_pattern), patbuf);
if (err != NULL)
But, this can't be right, can it?
It can, yes. But etags has completely zeroed the pattern buffer before
using it for three and a half years, looking forward to changes like the
one that hit you. You are using a very old version.
You can dowload the latest version from
<ftp://fly.isti.cnr.it/pub/etags.c.gz>
or, if you want the man page, a statically compiled etags for Linux and
some other docs
<ftp://fly.isti.cnr.it/pub/software/unix/etags.tar.gz>.
patbuf is allocated in etags.c and
it looks like it's not fully initialized, but if this fix is right,
how could the code ever have worked?
At the time when the code you are using was written, the pattern buffer
did not include the external_to_internal_register member. As soon as
you run it with a new version of regex.c that included the new member,
it broke.