Closed Bug 697105 Opened 8 years ago Closed 8 years ago

Permit spaces as a valid search query in an invalid URL

Categories

(Firefox for Android :: General, defect)

ARM
Android
defect
Not set

Tracking

()

VERIFIED FIXED

People

(Reporter: aaronmt, Assigned: mfinkle)

Details

(Whiteboard: [parity-opera][parity-stock][parity-dolphin])

Attachments

(1 file, 1 obsolete file)

STR:
1. "Toronto Ontario"
2. "The URL is not valid and cannot be loaded."

ER: https://www.google.com/q=toronto+ontario
AR: Dialog prompt

--
Mozilla/5.0 (Android; Linux armv7l; rv:10.0a1) Gecko/20111025 Firefox/10.0a1
Samsung Galaxy SII (Android 2.3.4)
Attached patch patch (obsolete) — Splinter Review
We load URLs directly in browserjs now, so we need to make sure those code paths are using 3RD_PARTY_FIXUP or nsIURIFixup.

This patch adds nsIURIFixup to Tab:Add and Tab:Load actions. I do wonder if we should show some kind of error dialog or error content page if the fixup fails.
Assignee: nobody → mark.finkle
Attachment #569598 - Flags: review?(doug.turner)
Attached patch patch 2Splinter Review
Fixed a typo i last patch "URIFixer" -> "URIFixup"
Attachment #569598 - Attachment is obsolete: true
Attachment #569598 - Flags: review?(doug.turner)
Attachment #569601 - Flags: review?(doug.turner)
Comment on attachment 569601 [details] [diff] [review]
patch 2

suppose URIFixup returns null.  we silently fail.  Is it better to just pass whatever we got to loadURI() or addTab()?

createFixupURI(aData, 1);

to:

createFixupURI(aData, Ci.nsIURIFixup.FIXUP_FLAG_ALLOW_KEYWORD_LOOKUP);

or

createFixupURI(aData, 1 /* FIXUP_FLAG_ALLOW_KEYWORD_LOOKUP */ );

or similar
Attachment #569601 - Flags: review?(doug.turner) → review+
(In reply to Doug Turner (:dougt) from comment #3)
> Comment on attachment 569601 [details] [diff] [review] [diff] [details] [review]
> patch 2
> 
> suppose URIFixup returns null.  we silently fail.  Is it better to just pass
> whatever we got to loadURI() or addTab()?

Done. We use the URI if not null, else we pass the original data

> createFixupURI(aData, Ci.nsIURIFixup.FIXUP_FLAG_ALLOW_KEYWORD_LOOKUP);

Done
https://hg.mozilla.org/projects/birch/rev/186015786b5a
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → FIXED
Mozilla/5.0 (Android; Linux armv7l; rv:10.0a1) Gecko/20111027 Firefox/10.0a1 Fennec/10.0a1
Samsung Nexus S
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.