Subject: Re: bug#70760: 29.3.50; core dumps when copy in other apps

From: Michael Albinus <[email-masked]>
Date: Thu, 16 May 2024 11:07:53 +0200

Kun Liu <[email-masked]> writes:

Hi,

> I did some more tests.

Thanks.

> On fresh start, I open a new org file, say '/tmp/test.org'. I will
> immediately see the following in *Messages* buffer. Opening other
> files (I tried csv, py, txt, cpp, c, java) has no such effect.

These traces come from dbusbind.c. They cover the D-Bus initialization
from Emacs POV, registering for signals and alike.

> xd_add_watch: fd 14, write 2, enabled 0
> xd_add_watch: fd 14, write 0, enabled 1
> Fdbus__init_bus: Registered buses: ((:system . 23518017264452))
> Fdbus__init_bus: Bus :system, Reference counter 2
> Fdbus_message_internal: DBUS_MESSAGE_TYPE_METHOD_CALL :system
> org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus
> AddMatch dbus-call-method-handler
> Fdbus_message_internal: Parameter1:
> type='signal',interface='org.freedesktop.DBus.Local',member='Disconnected',path='/org/freedesktop/DBus/Local'
>
> xd_signature: s
> xd_append_arg: s
> type='signal',interface='org.freedesktop.DBus.Local',member='Disconnected',path='/org/freedesktop/DBus/Local'
>
> Fdbus_message_internal: Message sent: (:serial :system 2)

This registers for signals from the :system bus, for calling methods.

> xd_retrieve_arg: s :1.492
> xd_read_message_1: Event received: DBUS_MESSAGE_TYPE_SIGNAL 2
> org.freedesktop.DBus :1.492 /org/freedesktop/DBus org.freedesktop.DBus
> NameAcquired ((:string :1.492))
> xd_read_message_1: Event received: DBUS_MESSAGE_TYPE_METHOD_RETURN 2
> org.freedesktop.DBus :1.492 (null) (null) (null) nil
> xd_read_message_1: Event stored: (:system 2 2 org.freedesktop.DBus :
> 1.492 nil nil nil dbus-call-method-handler)
> DBus-Event (dbus-event :system 2 2 org.freedesktop.DBus :1.492 nil nil
> nil dbus-call-method-handler) [3 times]
> Matching rule
> "type='signal',interface='org.freedesktop.DBus.Local',member='Disconnected',path='/org/freedesktop/DBus/Local'"
> created

This is the confirmation from D-Bus, that the registration was successful.

> xd_add_watch: fd 15, write 2, enabled 0
> xd_add_watch: fd 15, write 0, enabled 1
> Fdbus__init_bus: Registered buses: ((:session . 23518017267316)
> (:system . 23518017264452))
> Fdbus__init_bus: Bus :session, Reference counter 2
> Fdbus_message_internal: DBUS_MESSAGE_TYPE_METHOD_CALL :session
> org.freedesktop.DBus /org/freedesktop/DBus org.freedesktop.DBus
> AddMatch dbus-call-method-handler
> Fdbus_message_internal: Parameter1:
> type='signal',interface='org.freedesktop.DBus.Local',member='Disconnected',path='/org/freedesktop/DBus/Local'
>
> xd_signature: s
> xd_append_arg: s
> type='signal',interface='org.freedesktop.DBus.Local',member='Disconnected',path='/org/freedesktop/DBus/Local'
>
> Fdbus_message_internal: Message sent: (:serial :session 2)

This is the similar registration for the :session bus.

> xd_retrieve_arg: s :1.1051
> xd_read_message_1: Event received: DBUS_MESSAGE_TYPE_SIGNAL 2
> org.freedesktop.DBus :1.1051 /org/freedesktop/DBus
> org.freedesktop.DBus NameAcquired ((:string :1.1051))
> xd_read_message_1: Event received: DBUS_MESSAGE_TYPE_METHOD_RETURN 2
> org.freedesktop.DBus :1.1051 (null) (null) (null) nil
> xd_read_message_1: Event stored: (:session 2 2 org.freedesktop.DBus :
> 1.1051 nil nil nil dbus-call-method-handler)
> DBus-Event (dbus-event :session 2 2 org.freedesktop.DBus :1.1051 nil
> nil nil dbus-call-method-handler) [3 times]
> Matching rule
> "type='signal',interface='org.freedesktop.DBus.Local',member='Disconnected',path='/org/freedesktop/DBus/Local'"
> created

And this is the corresponding reply from D-Bus.

Everything normal, this initialization happens always. I guess you'll
see it also when starting Emacs with another file type but .org.

Best regards, Michael.