This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug other/67457] segfault in libbacktrace


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=67457

--- Comment #4 from Ian Lance Taylor <ian at airs dot com> ---
I committed a patch that should produce a more graceful fallback when out of
memory.  Please see if it helps your situation.

--- Comment #5 from ian at gcc dot gnu.org <ian at gcc dot gnu.org> ---
Author: ian
Date: Tue Sep  8 16:46:16 2015
New Revision: 227533

URL: https://gcc.gnu.org/viewcvs?rev=227533&root=gcc&view=rev
Log:
        PR other/67457
        * backtrace.c: #include "internal.h".
        (struct backtrace_data): Add can_alloc field.
        (unwind): If can_alloc is false, don't try to get file/line
        information.
        (backtrace_full): Set can_alloc field in bdata.
        * alloc.c (backtrace_alloc): Don't call error_callback if it is
        NULL.
        * mmap.c (backtrace_alloc): Likewise.
        * internal.h: Update comments for backtrace_alloc and
        backtrace_free.

Modified:
    trunk/libbacktrace/ChangeLog
    trunk/libbacktrace/alloc.c
    trunk/libbacktrace/backtrace.c
    trunk/libbacktrace/internal.h
    trunk/libbacktrace/mmap.c


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]