Commit c36af1b4 by Ian Lance Taylor Committed by Ian Lance Taylor

backtrace.c: Include backtrace-supported.h before checking BACKTRACE_USES_MALLOC.

	* backtrace.c: Include backtrace-supported.h before checking
	BACKTRACE_USES_MALLOC.

From-SVN: r259439
parent db051c24
2018-04-17 Ian Lance Taylor <iant@golang.org> 2018-04-17 Ian Lance Taylor <iant@golang.org>
* backtrace.c: Include backtrace-supported.h before checking
BACKTRACE_USES_MALLOC.
2018-04-17 Ian Lance Taylor <iant@golang.org>
* backtrace.c (backtrace_full): When testing whether we can * backtrace.c (backtrace_full): When testing whether we can
allocate memory, call mmap directly, and munmap the memory. allocate memory, call mmap directly, and munmap the memory.
......
...@@ -35,13 +35,14 @@ POSSIBILITY OF SUCH DAMAGE. */ ...@@ -35,13 +35,14 @@ POSSIBILITY OF SUCH DAMAGE. */
#include <unistd.h> #include <unistd.h>
#include <sys/types.h> #include <sys/types.h>
#include "backtrace-supported.h"
#if !BACKTRACE_USES_MALLOC #if !BACKTRACE_USES_MALLOC
#include <sys/mman.h> #include <sys/mman.h>
#endif #endif
#include "unwind.h" #include "unwind.h"
#include "backtrace.h" #include "backtrace.h"
#include "backtrace-supported.h"
#include "internal.h" #include "internal.h"
#ifndef MAP_ANONYMOUS #ifndef MAP_ANONYMOUS
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment