gdbus-monitor-接口`< none>` [英] gdbus-monitor - interface `<none>`

查看:184
本文介绍了gdbus-monitor-接口`< none>`的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

gdbus-monitor中的接口<none>是否输出特殊含义?

使用GDbus创建这样的消息需要什么API调用(g_dbus_connection_register_object不允许将NULL传递为GDBusInterfaceInfo *,并且这似乎是将对象注册到路径的唯一方法)

相关: dbus-在接口NULL上将对象注册到远程

解决方案

查看dbus-monitordbus - register object to remote on interface NULL

解决方案

Looking into dbus-monitor's source code shows that it occures as soon as DBUS_EXPORT const char * dbus_message_get_interface ( DBusMessage * message ) returns NULL (which is valid!, but not according to the spec which requires minimum one . and two name chunks!! EDIT: A noteable exception are method calls which do not require the interface field of a message to be set http://dbus.freedesktop.org/doc/dbus-specification.html#message-protocol-types).


g_dbus_message_new_method_call (...) allows interface_ to be null. But that still only solves half the problems (sender). The receiver method seems to not exist for interface_s being NULL.


Turns out it is a bug, I did a source code investigation and filed a bug (including fix) https://bugzilla.gnome.org/show_bug.cgi?id=706675

这篇关于gdbus-monitor-接口`&lt; none&gt;`的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆