[Pkg-gnupg-commit] [gnupg2] 51/116: common: Fix fallback code.

Daniel Kahn Gillmor dkg at fifthhorseman.net
Tue Jan 24 04:40:53 UTC 2017


This is an automated email from the git hooks/post-receive script.

dkg pushed a commit to branch master
in repository gnupg2.

commit bfd6a490129ffc7c7ac8776bf5a5da3b1ddf6d42
Author: Justus Winter <justus at g10code.com>
Date:   Tue Jan 10 12:31:46 2017 +0100

    common: Fix fallback code.
    
    * common/logging.c (_log_assert): Fix the variant for compilers that
    do not support __FUNCTION__.
    * common/logging.h (_log_assert): Likewise.
    
    Signed-off-by: Justus Winter <justus at g10code.com>
---
 common/logging.c | 2 +-
 common/logging.h | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/common/logging.c b/common/logging.c
index ca1341c..c06a34f 100644
--- a/common/logging.c
+++ b/common/logging.c
@@ -1007,7 +1007,7 @@ void
 _log_assert (const char *expr, const char *file, int line)
 {
   log_log (GPGRT_LOG_BUG, "Assertion \"%s\" failed (%s:%d)\n",
-           file, line, func);
+           expr, file, line);
   abort (); /* Never called; just to make the compiler happy.  */
 }
 #endif /*!GPGRT_HAVE_MACRO_FUNCTION*/
diff --git a/common/logging.h b/common/logging.h
index fc9e846..8edc5c9 100644
--- a/common/logging.h
+++ b/common/logging.h
@@ -62,7 +62,7 @@ estream_t log_get_stream (void);
    : _log_assert (#expr, __FILE__, __LINE__, __FUNCTION__))
 #else /*!GPGRT_HAVE_MACRO_FUNCTION*/
   void bug_at (const char *file, int line);
-  void _log_assert (const char *expr, const char *file, int line;
+  void _log_assert (const char *expr, const char *file, int line);
 # define BUG() bug_at( __FILE__ , __LINE__ )
 # define log_assert(expr)                                       \
   ((expr)                                                       \

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-gnupg/gnupg2.git



More information about the Pkg-gnupg-commit mailing list