From 36f53cb231e496cbb3def2ab6da1b3a110d45f80 Mon Sep 17 00:00:00 2001 From: Bruno Haible Date: Sun, 12 May 2024 15:58:32 +0200 Subject: [PATCH] execinfo: Document known bugs. * doc/glibc-functions/backtrace.texi: Mention the various bugs on FreeBSD, NetBSD, OpenBSD. * doc/glibc-functions/backtrace_symbols_fd.texi: Mention the glibc bug. --- ChangeLog | 7 +++++++ doc/glibc-functions/backtrace.texi | 10 ++++++++++ doc/glibc-functions/backtrace_symbols_fd.texi | 5 +++++ 3 files changed, 22 insertions(+) diff --git a/ChangeLog b/ChangeLog index 34d53eb4e1..2e2311e7b2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2024-05-12 Bruno Haible + + execinfo: Document known bugs. + * doc/glibc-functions/backtrace.texi: Mention the various bugs on + FreeBSD, NetBSD, OpenBSD. + * doc/glibc-functions/backtrace_symbols_fd.texi: Mention the glibc bug. + 2024-05-12 Bruno Haible execinfo tests: Strengthen tests. diff --git a/doc/glibc-functions/backtrace.texi b/doc/glibc-functions/backtrace.texi index b9a56094c1..ef2a3ac657 100644 --- a/doc/glibc-functions/backtrace.texi +++ b/doc/glibc-functions/backtrace.texi @@ -32,6 +32,16 @@ Portability problems not fixed by Gnulib: The second argument is of type @code{size_t}, not @code{int}, on some platforms: FreeBSD, NetBSD, OpenBSD. @item +The return value may be @code{(size_t)(-1)} instead of 0 on some platforms: +FreeBSD 12.4/i386. +@item +The returned stack trace is empty if it would not entirely fit into the +provided buffer on some platforms: +FreeBSD 14.0, NetBSD 10.0, OpenBSD 7.5. +@item +The returned stack trace is always empty on some platforms: +FreeBSD 11.0/i386, FreeBSD 12.2/sparc64. +@item On platforms where the function is missing, the Gnulib substitute implementation is just a stub, and does nothing. @end itemize diff --git a/doc/glibc-functions/backtrace_symbols_fd.texi b/doc/glibc-functions/backtrace_symbols_fd.texi index fe97b44b35..71461ebcac 100644 --- a/doc/glibc-functions/backtrace_symbols_fd.texi +++ b/doc/glibc-functions/backtrace_symbols_fd.texi @@ -32,6 +32,11 @@ Portability problems not fixed by Gnulib: The second argument is of type @code{size_t}, not @code{int}, on some platforms: FreeBSD, NetBSD, OpenBSD. @item +The strings printed by this function not the same as the strings returned by +@code{backtrace_symbols} on some platforms: +@c https://sourceware.org/bugzilla/show_bug.cgi?id=31730 +glibc 2.39. +@item On platforms where the function is missing, the Gnulib substitute implementation is just a stub, and does nothing. @end itemize -- 2.39.5