Closed Bug 569138 Opened 14 years ago Closed 14 years ago

Extension with empty minVersion and/or maxVersion breaks Add-ons Manager

Categories

(Toolkit :: Add-ons Manager, defect)

defect
Not set
major

Tracking

()

VERIFIED FIXED
mozilla2.0b1
Tracking Status
blocking2.0 --- final+

People

(Reporter: whimboo, Assigned: mossop)

References

Details

(Whiteboard: [AddonsRewrite])

Attachments

(1 file)

Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.3a5pre) Gecko/20100530 Minefield/3.7a5pre (.NET CLR 3.5.30729)

While trying to verify bug 567184 I was playing with some of the extensions and their install.rdf files and have seen that extensions can break the complete Add-ons Manager when an empty minVersion and/or maxVersion field is specified.

    <em:targetApplication>
      <Description>
        <em:id>{ec8030f7-c20a-464f-9b0e-13a3a9e97384}</em:id>
        <em:minVersion></em:minVersion>
        <em:maxVersion></em:maxVersion>
      </Description>
    </em:targetApplication>

After such an extension is modified on disk the Add-ons Manager doesn't show up any of the installed extensions.

Steps:
1. Install any extension
2. Edit its install.rdf file and remove the values for minVersion and/or maxVersion
3. Delete the extensions.sqlite
4. Restart Firefox
5. Open the Add-ons Manager
The error which is shown in the error console:

Error: ERROR addons.xpi: Error processing file changes: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIFile.remove]"  nsresult: "0x80004005 (NS_ERROR_FAILURE)"  location: "JS frame :: file:///C:/mozilla/bin/minefield/modules/XPIProvider.jsm :: DirInstallLocation_uninstallAddon :: line 5054"  data: no]
Flags: in-testsuite?
blocking2.0: ? → final+
Forgot about this one, it was fixed by bug 570484. Should add a quick testcase for it though.
Assignee: nobody → dtownsend
Depends on: 570484
Flags: in-litmus-
Target Milestone: --- → mozilla1.9.3a6
Status: NEW → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Attached patch testsSplinter Review
Some test cases for this and surrounding issues.
Attachment #454284 - Flags: review?(robert.bugzilla)
Verified fixed with Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.3a6pre) Gecko/20100625 Minefield/3.7a6pre
Status: RESOLVED → VERIFIED
Attachment #454284 - Flags: review?(robert.bugzilla) → review+
Landed testcase: http://hg.mozilla.org/mozilla-central/rev/da19603c8e2b
Flags: in-testsuite? → in-testsuite+
Target Milestone: mozilla1.9.3b1 → mozilla1.9.3
Target Milestone: mozilla1.9.3 → mozilla1.9.3b1
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: