From 5182ea70c8425d302c31386a325b869fcfef9671 Mon Sep 17 00:00:00 2001
From: Thorsten Kukuk <kukuk@thkukuk.de>
Date: Fri, 27 Mar 2009 10:46:11 +0000
Subject: Relevant BUGIDs:

Purpose of commit: bugfix

Commit summary:
---------------

2009-03-27  Thorsten Kukuk  <kukuk@thkukuk.de>

        * modules/pam_unix/support.c (_unix_run_helper_binary): Don't
        ignore return value of write().

        * libpamc/include/security/pam_client.h (PAM_BP_ASSERT): Honour
        NDEBUG.
        * modules/pam_timestamp/pam_timestamp.c: don't ignore return
        values of lchown and fchown.
---
 libpamc/include/security/pam_client.h | 12 ++++++++----
 1 file changed, 8 insertions(+), 4 deletions(-)

(limited to 'libpamc')

diff --git a/libpamc/include/security/pam_client.h b/libpamc/include/security/pam_client.h
index 7fd195a5..988c2456 100644
--- a/libpamc/include/security/pam_client.h
+++ b/libpamc/include/security/pam_client.h
@@ -9,8 +9,8 @@
 #ifndef PAM_CLIENT_H
 #define PAM_CLIENT_H
 
-#ifdef __cplusplus 
-extern "C" { 
+#ifdef __cplusplus
+extern "C" {
 #endif /* def __cplusplus */
 
 #include <unistd.h>
@@ -74,8 +74,12 @@ char **pamc_list_agents(pamc_handle_t pch);
 #include <unistd.h>
 
 #ifndef PAM_BP_ASSERT
-# define PAM_BP_ASSERT(x)   do { printf(__FILE__ "(%d): %s\n", \
-					__LINE__, x) ; exit(1); } while (0)
+# ifdef NDEBUG
+#  define PAM_BP_ASSERT(x)   do {} while (0)
+# else
+#  define PAM_BP_ASSERT(x)   do { printf(__FILE__ "(%d): %s\n", \
+					 __LINE__, x) ; exit(1); } while (0)
+# endif /* NDEBUG */
 #endif /* PAM_BP_ASSERT */
 
 #ifndef PAM_BP_CALLOC
-- 
cgit v1.2.3