Mercurial > gnulib
view doc/error.texi @ 37246:5cfb3a67238d
regex: avoid glibc deadlock during configure
glibc has a known bug where certain corruptions of the heap can
cause malloc to default to printing a debug message that includes
a backtrace, but the act of getting the backtrace uses dlopen
which in turn calls into malloc, causing a recursive lock ending
in deadlock. Thus, when configure is probing for a known glibc
heap corruption bug, the overall configure would hang.
The solution suggested by glibc developers is to force malloc
to quit printing debug messages, which avoids recursive malloc.
* m4/regex.m4 (gl_REGEX): Avoid recursive malloc deadlock when
glibc bug 15078 in turn triggers bug 16159.
Reported by Michal Privoznik.
Signed-off-by: Eric Blake <eblake@redhat.com>
author | Eric Blake <eblake@redhat.com> |
---|---|
date | Tue, 03 Dec 2013 10:34:13 -0700 |
parents | c741bc27922a |
children | 344018b6e5d7 |
line wrap: on
line source
@node error and progname @section error and progname @findex error @findex progname @vindex program_name @c Copyright (C) 2007, 2009-2013 Free Software Foundation, Inc. @c Permission is granted to copy, distribute and/or modify this document @c under the terms of the GNU Free Documentation License, Version 1.3 or @c any later version published by the Free Software Foundation; with no @c Invariant Sections, with no Front-Cover Texts, and with no Back-Cover @c Texts. A copy of the license is included in the ``GNU Free @c Documentation License'' file as part of this distribution. The @code{error} function uses the @code{program_name} variable, but does not depend on the @code{progname} module. Why? Because @code{error} is released under the LGPL, whereas @code{progname} is GPL. RMS does not want additional baggage accompanying the @code{error} module, so an LGPL user must provide their own replacement @code{program_name}, and a GPL user should manually specify using the @code{progname} module. Additionally, using the @code{progname} module is not something that can be done implicitly. It requires that every @code{main} function be modified to set @code{program_name} as one of its first actions.