Closed Bug 917965 Opened 6 years ago Closed 6 years ago

UA overrides are disabled if update is invalid

Categories

(Core :: Networking: HTTP, defect)

All
Gonk (Firefox OS)
defect
Not set

Tracking

()

RESOLVED FIXED
mozilla27
blocking-b2g koi+
Tracking Status
firefox25 --- wontfix
firefox26 --- fixed
firefox27 --- fixed
b2g-v1.2 --- fixed

People

(Reporter: jchen, Assigned: jchen)

References

Details

Attachments

(1 file)

If an update is invalid (i.e. request succeeds but the content is invalid), the UA override list will be set to null, effectively disabling overrides. We should keep the old list instead.
Prevent null UA override list
Attachment #807789 - Flags: review?(fabrice)
Noming for 1.2 too.
blocking-b2g: --- → koi?
Attachment #807789 - Flags: review?(fabrice) → review+
blocking-b2g: koi? → koi+
https://hg.mozilla.org/mozilla-central/rev/f9bc1da07766
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla27
Keywords: verifyme
Is there any way I can simulate invalid updates in order to reproduce/verify this bug?
(In reply to Ioana Budnar, QA [:ioana] from comment #6)
> Is there any way I can simulate invalid updates in order to reproduce/verify
> this bug?

It's a bit complicated. With the latest build of B2G, 

1) Verify r7.com in the browser displays the mobile site and not the desktop site
2) Set the pref "general.useragent.updates.url" to "http://people.mozilla.org/~nchen/ua/ua-invalid.json"
3) Set the pref "general.useragent.updates.interval" to 60
4) Wait 5 minutes for the update to occur
5) Verify r7.com still displays the mobile site and not the desktop site
Thanks for the steps but, unfortunately, I don't have access to B2G devices. Does this bug also affect Firefox for desktop somehow?
Flags: needinfo?(nchen)
(In reply to Ioana Budnar, QA [:ioana] from comment #8)
> Thanks for the steps but, unfortunately, I don't have access to B2G devices.
> Does this bug also affect Firefox for desktop somehow?

Unfortunately the code only runs on B2G. Maybe a B2G QA can verify this.
Flags: needinfo?(nchen)
Dropping verifyme because the flag was added for Firefox Desktop.
Keywords: verifyme
OS: All → Gonk (Firefox OS)
You need to log in before you can comment on or make changes to this bug.