Closed Bug 1705130 Opened 3 years ago Closed 3 years ago

DBus introspection gives OpenURL argument as string instead of array-of-bytes

Categories

(Core :: Widget: Gtk, defect)

Firefox 87
defect

Tracking

()

RESOLVED FIXED
89 Branch
Tracking Status
firefox89 --- fixed

People

(Reporter: takowl, Assigned: takowl)

Details

Attachments

(2 files)

User Agent: Mozilla/5.0 (X11; Fedora; Linux x86_64; rv:87.0) Gecko/20100101 Firefox/87.0

Steps to reproduce:

Inspect the D-Bus API exposed by org.mozilla.firefox.ZGVmYXVsdA__ (Firefox running with the default profile) using a tool such as D-Feet (https://wiki.gnome.org/Apps/DFeet ).

Actual results:

The OpenURL method has a string parameter.

Expected results:

The parameter should be an array of bytes (dbus signature "ay").

The D-Bus specification is clear that strings are UTF-8 without null bytes. The parameter in Firefox contains a mixture of null terminated strings and integers as binary data. The code that actually constructs (nsDBusRemoteClient::DoSendDBusCommandLine) and handles (nsDBusRemoteServer::OpenURL) the message is clear that it's using an array of bytes: only the introspection XML is wrong.

(Maybe it would be even better to pass an array of strings, or an array of arrays of bytes, using D-Bus's serialisation rather than packing several arguments into an array of bytes. But that's a bigger change.)

Assignee: nobody → takowl

The Bugbug bot thinks this bug should belong to the 'Core::Widget: Gtk' component, and is moving the bug to that component. Please revert this change in case you think the bot is wrong.

Component: Untriaged → Widget: Gtk
Product: Firefox → Core
Pushed by stransky@redhat.com:
https://hg.mozilla.org/integration/autoland/rev/5e5fbe1c6508
Correct argument type in D-Bus introspection XML. r=stransky
Status: UNCONFIRMED → RESOLVED
Closed: 3 years ago
Resolution: --- → FIXED
Target Milestone: --- → 89 Branch
You need to log in before you can comment on or make changes to this bug.