[gnutls-devel] 3.3.0pre0 - [sparc] Bus error on chainverify test

Nikos Mavrogiannopoulos nmav at gnutls.org
Tue Apr 1 11:21:17 CEST 2014

On Sun, Mar 30, 2014 at 7:37 PM, Andreas Metzler <ametzler at bebt.de> wrote:
> Hello,
> Program received signal SIGBUS, Bus error.
> asn1_delete_structure2 (structure=0x1bf10, flags=0) at structure.c:315
> 315           if (p->down)
> (gdb) bt
> #0  asn1_delete_structure2 (structure=0x1bf10, flags=0) at structure.c:315
> #1  0xf7f3f18c in gnutls_x509_crt_import (cert=0x1bf10, data=0xffffd668,
>     format=GNUTLS_X509_FMT_PEM) at x509.c:207
> #2  0x00010f40 in doit () at chainverify.c:1279
> #3  0x00010b30 in main (argc=0, argv=0xffffd7c4) at utils.c:146
> (gdb)
> -------------
> I have built against included minitasn for improved debugging output.

Andreas, could there be an issue with calloc or the compiler on this
system? If you
follow the code in gnutls_x509_crt_import() it only enters the
location that receives
sigbus  when 'cert->expanded' is non zero. As this is the first call
after gnutls_x509_crt_init()
it means that this value should have been zero.

A way to see if it is a compiler issue, is to change the compiler, or
try compiling with -O0 (and
hoping the issue is in the optimizer). You can see if it is an issue
in calloc() on that system
by placing a memset() to zero just after it and seeing whether it
fixes the issue.


More information about the Gnutls-devel mailing list