diff --git a/src/dbusbind.c b/src/dbusbind.c index ec3707d18f3..fe922d5429b 100644 --- a/src/dbusbind.c +++ b/src/dbusbind.c @@ -1419,7 +1419,7 @@ usage: (dbus-message-internal &rest REST) */) for (; count < nargs; ++count) { dtype = XD_OBJECT_TO_DBUS_TYPE (args[count]); - if (XD_DBUS_TYPE_P (args[count])) + if (count + 1 < nargs && XD_DBUS_TYPE_P (args[count])) { XD_DEBUG_VALID_LISP_OBJECT_P (args[count]); XD_DEBUG_VALID_LISP_OBJECT_P (args[count+1]);