[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] trunk r117477: Fix Bug#17858
From: |
Michael Albinus |
Subject: |
[Emacs-diffs] trunk r117477: Fix Bug#17858 |
Date: |
Fri, 04 Jul 2014 10:03:27 +0000 |
User-agent: |
Bazaar (2.6b2) |
------------------------------------------------------------
revno: 117477
revision-id: address@hidden
parent: address@hidden
committer: Michael Albinus <address@hidden>
branch nick: trunk
timestamp: Fri 2014-07-04 12:03:14 +0200
message:
Fix Bug#17858
* net/dbus.el (dbus-peer-handler): New defun.
(dbus-register-service): Register it.
(dbus-managed-objects-handler): Fix docstring.
modified:
lisp/ChangeLog changelog-20091113204419-o5vbwnq5f7feedwu-1432
lisp/net/dbus.el dbus.el-20091113204419-o5vbwnq5f7feedwu-7962
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog 2014-07-04 02:00:54 +0000
+++ b/lisp/ChangeLog 2014-07-04 10:03:14 +0000
@@ -1,3 +1,9 @@
+2014-07-04 Michael Albinus <address@hidden>
+
+ * net/dbus.el (dbus-peer-handler): New defun.
+ (dbus-register-service): Register it. (Bug#17858)
+ (dbus-managed-objects-handler): Fix docstring.
+
2014-07-04 Phil Sainty <address@hidden> (tiny change)
* emacs-lisp/lisp.el (narrow-to-defun-include-comments): New var.
@@ -1762,7 +1768,7 @@
Remove HISTFILE and HISTSIZE; it's too late to set them here.
Add :version entry.
(tramp-open-shell): Do not let-bind `tramp-end-of-output'.
- Add "HISTSIZE=/dev/null" to the shell's env arguments. Do not send
+ Add "HISTFILE=/dev/null" to the shell's env arguments. Do not send
extra "PSx=..." commands.
(tramp-maybe-open-connection): Setenv HISTFILE to /dev/null.
(Bug#17295)
@@ -3462,7 +3468,7 @@
2014-03-10 Michael Albinus <address@hidden>
* net/tramp-sh.el (tramp-open-connection-setup-interactive-shell):
- Do not add `nil' to the environment, when there's no remote `locale'.
+ Do not add nil to the environment, when there's no remote `locale'.
(tramp-find-inline-encoding): Check, that the remote host has
installed perl, before sending scripts.
=== modified file 'lisp/net/dbus.el'
--- a/lisp/net/dbus.el 2014-06-15 12:15:25 +0000
+++ b/lisp/net/dbus.el 2014-07-04 10:03:14 +0000
@@ -544,6 +544,10 @@
`:already-owner': Service is already the primary owner."
+ ;; Add Peer handler.
+ (dbus-register-method
+ bus service nil dbus-interface-peer "Ping" 'dbus-peer-handler
'dont-register)
+
;; Add ObjectManager handler.
(dbus-register-method
bus service nil dbus-interface-objectmanager "GetManagedObjects"
@@ -1151,6 +1155,22 @@
bus service dbus-path-dbus dbus-interface-peer "Ping")))
(dbus-error nil)))
+(defun dbus-peer-handler ()
+ "Default handler for the \"org.freedesktop.DBus.Peer\" interface.
+It will be registered for all objects created by `dbus-register-service'."
+ (let* ((last-input-event last-input-event)
+ (method (dbus-event-member-name last-input-event)))
+ (cond
+ ;; "Ping" does not return an output parameter.
+ ((string-equal method "Ping")
+ :ignore)
+ ;; "GetMachineId" returns "s".
+ ((string-equal method "GetMachineId")
+ (signal
+ 'dbus-error
+ (list
+ (format "%s.GetMachineId not implemented" dbus-interface-peer)))))))
+
;;; D-Bus introspection.
@@ -1672,7 +1692,7 @@
(defun dbus-managed-objects-handler ()
"Default handler for the \"org.freedesktop.DBus.ObjectManager\" interface.
-It will be registered for all objects created by `dbus-register-method'."
+It will be registered for all objects created by `dbus-register-service'."
(let* ((last-input-event last-input-event)
(bus (dbus-event-bus-name last-input-event))
(path (dbus-event-path-name last-input-event)))
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] trunk r117477: Fix Bug#17858,
Michael Albinus <=