diff options
author | Tobias Brunner <tobias@strongswan.org> | 2013-03-08 16:43:07 +0100 |
---|---|---|
committer | Tobias Brunner <tobias@strongswan.org> | 2013-03-08 16:45:09 +0100 |
commit | 2b1e2434e422b1701184b594bc386b1532da75af (patch) | |
tree | 5b2b16956ee37bc78295267b71b0c4cbb7442284 | |
parent | 292ee515db5ecaeccf54098fb05b1beeef297a7f (diff) | |
download | strongswan-2b1e2434e422b1701184b594bc386b1532da75af.tar.bz2 strongswan-2b1e2434e422b1701184b594bc386b1532da75af.tar.xz |
esc() is only used if dladdr(3) is available5.0.3dr3
-rw-r--r-- | src/libstrongswan/utils/backtrace.c | 25 |
1 files changed, 13 insertions, 12 deletions
diff --git a/src/libstrongswan/utils/backtrace.c b/src/libstrongswan/utils/backtrace.c index 45571981e..77137f9f1 100644 --- a/src/libstrongswan/utils/backtrace.c +++ b/src/libstrongswan/utils/backtrace.c @@ -53,18 +53,6 @@ struct private_backtrace_t { }; /** - * Same as tty_escape_get(), but for a potentially NULL FILE* - */ -static char* esc(FILE *file, tty_escape_t escape) -{ - if (file) - { - return tty_escape_get(fileno(file), escape); - } - return ""; -} - -/** * Write a format string with arguments to a FILE line, if it is NULL to DBG */ static void println(FILE *file, char *format, ...) @@ -87,6 +75,19 @@ static void println(FILE *file, char *format, ...) } #ifdef HAVE_DLADDR + +/** + * Same as tty_escape_get(), but for a potentially NULL FILE* + */ +static char* esc(FILE *file, tty_escape_t escape) +{ + if (file) + { + return tty_escape_get(fileno(file), escape); + } + return ""; +} + #ifdef HAVE_BFD_H #include <bfd.h> |