]> git.puffer.fish Git - mirror/frr.git/commitdiff
2004-12-09 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
authorajs <ajs>
Thu, 9 Dec 2004 17:26:31 +0000 (17:26 +0000)
committerajs <ajs>
Thu, 9 Dec 2004 17:26:31 +0000 (17:26 +0000)
* log.c: (hex_append) No need to include this function if
  HAVE_GLIBC_BACKTRACE is not defined.

lib/ChangeLog
lib/log.c

index faf6b1853f35576dda7cef1fa38acc44191d9290..a4f79deb28bf34e956650a98b44b5303fe9ca357 100644 (file)
@@ -1,3 +1,8 @@
+2004-12-09 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
+
+       * log.c: (hex_append) No need to include this function if
+         HAVE_GLIBC_BACKTRACE is not defined.
+
 2004-12-08 Andrew J. Schorr <ajschorr@alumni.princeton.edu>
 
        * prefix.c: (prefix_copy) Error message before abort should
index 64d576a2fa09100deb2954cd1be2bf8f99dcc825..ec9586457b2741fcb6caff9a2a20ec70e9b79545 100644 (file)
--- a/lib/log.c
+++ b/lib/log.c
@@ -1,5 +1,5 @@
 /*
- * $Id: log.c,v 1.18 2004/12/09 14:53:32 gdt Exp $
+ * $Id: log.c,v 1.19 2004/12/09 17:26:31 ajs Exp $
  *
  * Logging of zebra
  * Copyright (C) 1997, 1998, 1999 Kunihiro Ishiguro
@@ -177,10 +177,10 @@ num_append(char *s, int len, u_long x)
   return str_append(s,len,t);
 }
 
-/*
- * XXX warning: `hex_append' defined but not used
- * Apparently this is used only if HAVE_GLIBC_BACKTRACE is defined.
- */
+#ifdef HAVE_GLIBC_BACKTRACE
+
+/* This function is used only in zlog_backtrace_sigsafe when glibc
  backtraces are available. */
 static char *
 hex_append(char *s, int len, u_long x)
 {
@@ -199,6 +199,8 @@ hex_append(char *s, int len, u_long x)
   return str_append(s,len,t);
 }
 
+#endif /* HAVE_GLIBC_BACKTRACE */
+
 static int syslog_fd = -1;
 
 /* Needs to be enhanced to support Solaris. */