[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] /srv/bzr/emacs/trunk r100802: * dbusbind.c (xd_initialize)
From: |
Andreas Schwab |
Subject: |
[Emacs-diffs] /srv/bzr/emacs/trunk r100802: * dbusbind.c (xd_initialize): Don't compare boolean with a constant. |
Date: |
Mon, 12 Jul 2010 21:03:53 +0200 |
User-agent: |
Bazaar (2.0.3) |
------------------------------------------------------------
revno: 100802
committer: Andreas Schwab <address@hidden>
branch nick: emacs
timestamp: Mon 2010-07-12 21:03:53 +0200
message:
* dbusbind.c (xd_initialize): Don't compare boolean with a constant.
modified:
src/ChangeLog
src/dbusbind.c
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2010-07-12 18:44:35 +0000
+++ b/src/ChangeLog 2010-07-12 19:03:53 +0000
@@ -1,3 +1,8 @@
+2010-07-12 Andreas Schwab <address@hidden>
+
+ * dbusbind.c (xd_initialize): Don't compare boolean with a
+ constant.
+
2010-07-12 Eli Zaretskii <address@hidden>
* process.c (setup_process_coding_systems): Move to the part
=== modified file 'src/dbusbind.c'
--- a/src/dbusbind.c 2010-07-09 09:05:47 +0000
+++ b/src/dbusbind.c 2010-07-12 19:03:53 +0000
@@ -714,9 +714,9 @@
}
/* Initialize D-Bus connection. BUS is a Lisp symbol, either :system
- or :session. It tells which D-Bus to be initialized. RAISE_ERROR
- can be TRUE or FALSE, it controls whether an error is signalled in
- case the connection cannot be initialized. */
+ or :session. It tells which D-Bus to initialize. If RAISE_ERROR
+ is non-zero signal an error when the connection cannot be
+ initialized. */
static DBusConnection *
xd_initialize (Lisp_Object bus, int raise_error)
{
@@ -726,7 +726,7 @@
/* Parameter check. */
CHECK_SYMBOL (bus);
if (!(EQ (bus, QCdbus_system_bus) || EQ (bus, QCdbus_session_bus)))
- if (raise_error == TRUE)
+ if (raise_error)
XD_SIGNAL2 (build_string ("Wrong bus name"), bus);
else
return NULL;
@@ -734,7 +734,7 @@
/* We do not want to have an autolaunch for the session bus. */
if (EQ (bus, QCdbus_session_bus)
&& getenv ("DBUS_SESSION_BUS_ADDRESS") == NULL)
- if (raise_error == TRUE)
+ if (raise_error)
XD_SIGNAL2 (build_string ("No connection to bus"), bus);
else
return NULL;
@@ -748,12 +748,12 @@
connection = dbus_bus_get (DBUS_BUS_SESSION, &derror);
if (dbus_error_is_set (&derror))
- if (raise_error == TRUE)
+ if (raise_error)
XD_ERROR (derror);
else
connection = NULL;
- if ((connection == NULL) && (raise_error == TRUE))
+ if (connection == NULL && raise_error)
XD_SIGNAL2 (build_string ("No connection to bus"), bus);
/* Cleanup. */
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] /srv/bzr/emacs/trunk r100802: * dbusbind.c (xd_initialize): Don't compare boolean with a constant.,
Andreas Schwab <=