Bug 103125 - xdg-desktop-menu adds entries to defaults.list
Summary: xdg-desktop-menu adds entries to defaults.list
Status: RESOLVED MOVED
Alias: None
Product: Portland
Classification: Unclassified
Component: xdg-utils (show other bugs)
Version: 1.1.0
Hardware: All All
: medium normal
Assignee: Portland Bugs
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-10-06 13:50 UTC by Dmitry Mikhirev
Modified: 2019-02-16 13:39 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Dmitry Mikhirev 2017-10-06 13:50:15 UTC
The xdg-desktop-menu script, when installing a menu entry, sets the application as default handler for MIME types that are listed in its desktop file. This behavior was introduced in commit 1f7f2ea7 with the following message:

> Make application the default handler for a mimetype if it is the only
> handler for that mimetype so far.

In fact, this is incorrect. xdg-desktop-menu does not check if there are other handlers or not, it only checks that there's no *default* handler already set. Even if it performed such a check, it would be strange to set the only possible handler as default explicitly.

I consider such a behavior is a misfeature. Is is not documented anywhere, and it is unexpected that the tool, the only purpose of which is to add a menu item, adds some MIME types associations. Furthermore, it is impossible to disable this (e.g via a command line option), and, as already reported in #71825, such an association is not removed when removing the corresponding menu entry or even when the application itself is being removed.

Please consider reverting commit 1f7f2ea7 and disabling such a strange behavior.
Comment 1 Rex Dieter 2017-10-06 14:29:40 UTC
I agree with your assessment that it is a misfeature
Comment 2 GitLab Migration User 2019-02-16 13:39:26 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/xdg/xdg-utils/issues/116.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.