unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* Alternative D-Bus connection (was: [ANN][SHR][Debian] New Emacs interface for FSO)
       [not found]   ` <20100819061124.GR8814@home.pavel.comp>
@ 2010-08-19  7:20     ` Michael Albinus
  2010-08-23 14:06     ` Alternative D-Bus connection Michael Albinus
  1 sibling, 0 replies; 2+ messages in thread
From: Michael Albinus @ 2010-08-19  7:20 UTC (permalink / raw)
  To: Paul Fertser; +Cc: List for Openmoko community discussion, emacs-devel

Paul Fertser <fercerpav@gmail.com> writes:

> Hi,

Hi,

> Michael, let me take this opportunity to thank you for all the
> wonderful opportunities opened by the D-Bus integration in Emacs, it
> really rocks :)

Thank you.

> Yes, to the best of my understanding to leverage this restriction one
> needs to modify dbusbind.c. Currently the emacs bindings accept only
> :session or :system for the bus name and use dbus_bus_get() to get one
> of them. It should support also arbitrary strings and call
> dbus_connection_open() instead (in xd_initialize()).

Some months ago, I have done exactly this (I've played with D-Bus
tubes). It did work already to some extent. It shouldn't be too hard to
find my old code, and to commit it to the Emacs trunk.

> One should also not forget to call dbus_connection_unref() after he's
> done (according to
> http://dbus.freedesktop.org/doc/api/html/group__DBusConnection.html).
> I also suspect that dbus_bus_get has an interesting undesired
> side-effect: it'll kill the app if connection drops.  Not exactly what
> you want to be done with your emacs.

Thanks for the hint, I'll check.

> OTOH, i'm not sure this usecase is worth caring about. At least i know
> i'm the only user of fso.el and i do not really need that :/

At least we are now two who want to connect to alternative buses :-)

Best regards, Michael.



^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Alternative D-Bus connection
       [not found]   ` <20100819061124.GR8814@home.pavel.comp>
  2010-08-19  7:20     ` Alternative D-Bus connection (was: [ANN][SHR][Debian] New Emacs interface for FSO) Michael Albinus
@ 2010-08-23 14:06     ` Michael Albinus
  1 sibling, 0 replies; 2+ messages in thread
From: Michael Albinus @ 2010-08-23 14:06 UTC (permalink / raw)
  To: List for Openmoko community discussion; +Cc: emacs-devel

Paul Fertser <fercerpav@gmail.com> writes:

> Hi,

Hi,

> Yes, to the best of my understanding to leverage this restriction one
> needs to modify dbusbind.c. Currently the emacs bindings accept only
> :session or :system for the bus name and use dbus_bus_get() to get one
> of them. It should support also arbitrary strings and call
> dbus_connection_open() instead (in xd_initialize()). One should also
> not forget to call dbus_connection_unref() after he's done (according to
> http://dbus.freedesktop.org/doc/api/html/group__DBusConnection.html).

I've just committed some patches to the trunk which allow accessing
alternative buses. If you are interested in, you might try it.

> I also suspect that dbus_bus_get has an interesting undesired
> side-effect: it'll kill the app if connection drops.  Not exactly what
> you want to be done with your emacs.

I reset this by

  dbus_connection_set_exit_on_disconnect (connection, FALSE);

Best regards, Michael.



^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-08-23 14:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <m2zl02mawy.fsf@home.pavel.comp>
     [not found] ` <8739ub655m.fsf@gmx.de>
     [not found]   ` <20100819061124.GR8814@home.pavel.comp>
2010-08-19  7:20     ` Alternative D-Bus connection (was: [ANN][SHR][Debian] New Emacs interface for FSO) Michael Albinus
2010-08-23 14:06     ` Alternative D-Bus connection Michael Albinus

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).