dbus/dbus dbus-internals.c,1.45,1.46

John Palmieri johnp at kemper.freedesktop.org
Tue Aug 8 13:22:16 PDT 2006


Update of /cvs/dbus/dbus/dbus
In directory kemper:/tmp/cvs-serv12428/dbus

Modified Files:
	dbus-internals.c 
Log Message:
* dbus/dbus-internals.c: unistd.h is not used
  (_dbus_verbose_real): only enable verbose printing
  if DBUS_VERBOSE environment var is set to '1'
  (patch from Peter Kümmel <syntheticpp at gmx dot net>


Index: dbus-internals.c
===================================================================
RCS file: /cvs/dbus/dbus/dbus/dbus-internals.c,v
retrieving revision 1.45
retrieving revision 1.46
diff -u -d -r1.45 -r1.46
--- dbus-internals.c	3 Aug 2006 20:34:36 -0000	1.45
+++ dbus-internals.c	8 Aug 2006 20:22:14 -0000	1.46
@@ -28,7 +28,6 @@
 #include <string.h>
 #include <sys/types.h>
 #include <errno.h>
-#include <unistd.h>
 #include <fcntl.h>
 #include <stdlib.h>
 
@@ -246,7 +245,8 @@
   
   if (!verbose_initted)
     {
-      verbose = _dbus_getenv ("DBUS_VERBOSE") != NULL;
+      const char *p = _dbus_getenv ("DBUS_VERBOSE"); 
+      verbose = p != NULL && *p == '1';
       verbose_initted = TRUE;
       if (!verbose)
         return;



More information about the dbus-commit mailing list