Gitweb links:
...log
http://git.netsurf-browser.org/netsurf.git/shortlog/d71d2632b42c7253a2e6d873a78d4fb458036484
...commit
http://git.netsurf-browser.org/netsurf.git/commit/d71d2632b42c7253a2e6d873a78d4fb458036484
...tree
http://git.netsurf-browser.org/netsurf.git/tree/d71d2632b42c7253a2e6d873a78d4fb458036484
The branch, master has been updated
via d71d2632b42c7253a2e6d873a78d4fb458036484 (commit)
from ed6c326b1c6643a6f0516cf2e613eb85781ab5b6 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commitdiff
http://git.netsurf-browser.org/netsurf.git/commit/?id=d71d2632b42c7253a2e6d873a78d4fb458036484
commit d71d2632b42c7253a2e6d873a78d4fb458036484
Author: Vincent Sanders <[email protected]>
Commit: Vincent Sanders <[email protected]>
limit monkey backtrace generation to libc where it is available
diff --git a/frontends/monkey/main.c b/frontends/monkey/main.c
index a893144..1aced80 100644
--- a/frontends/monkey/main.c
+++ b/frontends/monkey/main.c
@@ -316,7 +316,7 @@ static void monkey_run(void)
}
}
-#ifndef NDEBUG
+#if (!defined(NDEBUG) && defined(HAVE_EXECINFO))
#include <execinfo.h>
static void *backtrace_buffer[4096];
@@ -325,7 +325,9 @@ __assert_fail(const char *__assertion, const char *__file,
unsigned int __line, const char *__function)
{
int frames;
- fprintf(stderr, "MONKEY: Assertion failure!\n%s:%d: %s: Assertion `%s`
failed.\n",
+ fprintf(stderr,
+ "MONKEY: Assertion failure!\n"
+ "%s:%d: %s: Assertion `%s` failed.\n",
__file, __line, __function, __assertion);
frames = backtrace(&backtrace_buffer[0], 4096);
diff --git a/utils/config.h b/utils/config.h
index d3ec326..0227f41 100644
--- a/utils/config.h
+++ b/utils/config.h
@@ -151,6 +151,12 @@ char *realpath(const char *path, char *resolved_path);
#undef HAVE_REGEX
#endif
+/* execinfo available for backtrace */
+#if ((defined(__linux__) && defined(__GLIBC__) && !defined(__UCLIBC__)) || \
+ defined(__APPLE__))
+#define HAVE_EXECINFO
+#endif
+
/* This section toggles build options on and off.
* Simply undefine a symbol to turn the relevant feature off.
*
-----------------------------------------------------------------------
Summary of changes:
frontends/monkey/main.c | 6 ++++--
utils/config.h | 6 ++++++
2 files changed, 10 insertions(+), 2 deletions(-)
diff --git a/frontends/monkey/main.c b/frontends/monkey/main.c
index a893144..1aced80 100644
--- a/frontends/monkey/main.c
+++ b/frontends/monkey/main.c
@@ -316,7 +316,7 @@ static void monkey_run(void)
}
}
-#ifndef NDEBUG
+#if (!defined(NDEBUG) && defined(HAVE_EXECINFO))
#include <execinfo.h>
static void *backtrace_buffer[4096];
@@ -325,7 +325,9 @@ __assert_fail(const char *__assertion, const char *__file,
unsigned int __line, const char *__function)
{
int frames;
- fprintf(stderr, "MONKEY: Assertion failure!\n%s:%d: %s: Assertion `%s`
failed.\n",
+ fprintf(stderr,
+ "MONKEY: Assertion failure!\n"
+ "%s:%d: %s: Assertion `%s` failed.\n",
__file, __line, __function, __assertion);
frames = backtrace(&backtrace_buffer[0], 4096);
diff --git a/utils/config.h b/utils/config.h
index d3ec326..0227f41 100644
--- a/utils/config.h
+++ b/utils/config.h
@@ -151,6 +151,12 @@ char *realpath(const char *path, char *resolved_path);
#undef HAVE_REGEX
#endif
+/* execinfo available for backtrace */
+#if ((defined(__linux__) && defined(__GLIBC__) && !defined(__UCLIBC__)) || \
+ defined(__APPLE__))
+#define HAVE_EXECINFO
+#endif
+
/* This section toggles build options on and off.
* Simply undefine a symbol to turn the relevant feature off.
*
--
NetSurf Browser
_______________________________________________
netsurf-commits mailing list
[email protected]
http://listmaster.pepperfish.net/cgi-bin/mailman/listinfo/netsurf-commits-netsurf-browser.org