If I go to http://www.lequipe.fr/Football/Actualites/Menez-attend-un-signe/380997#xtor=RSS-1, I can't inspect the page due to the following failure: [Error] URIError: URI error displayNameForURL (Main.js, line 2894) _updateTitles (Main.js, line 2895) _updateResource (Main.js, line 2893) ResourceTreeElement (Main.js, line 2876) _addTreeElementForRepresentedObject (Main.js, line 3014) onpopulate (Main.js, line 2980) expand (Main.js, line 2405) _attach (Main.js, line 2364) insertChild (Main.js, line 2230) _mainFrameDidChange (Main.js, line 2743) dispatch (Main.js, line 278) dispatchEventToListeners (Main.js, line 280) _mainFrameDidChange (Main.js, line 1514) _processMainFrameResourceTreePayload (Main.js, line 1500) (anonymous function) dispatch (Main.js, line 388) dispatchNextQueuedMessageFromBackend (Main.js, line 8396) (anonymous function)
<rdar://problem/14244539>
The error is coming from calling decodeURIComponent() with this string as the value for urlComponents.lastPathComponent: http://ww84.smartadserver.com/call2/pubjallajax/2368/17167/2077,2078,647,2163,7186,7185,630,713,650,1278,7186,631,3075,4738,736,632,12340,1075,1446,651,648,16752/4891911503/xtor%3DRSS-1%3Bsize%3Dsmall%3BFOOTBALL%3BLIGUE_1%3BSAISON_2012-2013%3BPARIS-SG%3BMENEZ_JEREMY%3BTRANSFERTS_FOOTBALL%3BMERCATO_ETE_2013%3BINFO_L_%C9QUIPE%3BD1%3B? xtor%3DRSS-1%3Bsize%3Dsmall%3BFOOTBALL%3BLIGUE_1%3BSAISON_2012-2013%3BPARIS-SG%3BMENEZ_JEREMY%3BTRANSFERTS_FOOTBALL%3BMERCATO_ETE_2013%3BINFO_L_%C9QUIPE%3BD1%3B
It looks like urlComponents.lastPathComponent is just set incorrectly.
The problematic string passed todecodeURIComponent() is actually "xtor%3DRSS-1%3Bsize%3Dsmall%3BFOOTBALL%3BLIGUE_1%3BSAISON_2012-2013%3BPARIS-SG%3BMENEZ_JEREMY%3BTRANSFERTS_FOOTBALL%3BMERCATO_ETE_2013%3BINFO_L_%C9QUIPE%3BD1%3B"
"%C9" is the part of the string that yields the decodeURIComponent exception.
Looks like the URI encoding is incorrect, and "É" should be "%C3%89" and not "%C9", although some pages on the internets seem to suggest that's OK (http://www.degraeve.com/reference/urlencoding.php). But the RFC 3986 (http://tools.ietf.org/html/rfc3986) suggests otherwise (first full paragraph of page 16). We should just handle the possible exception thrown by decodeURIComponent() here.
Created attachment 205288 [details] Patch
Comment on attachment 205288 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=205288&action=review We should probably guard WebInspector.updateWindowTitle and parseQueryString too. > Source/WebInspectorUI/UserInterface/Main.js:360 > + displayName = decodeURIComponent(urlComponents.lastPathComponent || ""); > + } catch (e) { > + // Ignore possible URIError. We should fallback to urlComponents.lastPathComponent (not decoded) for displayName in the catch.
Created attachment 205289 [details] Patch for landing
Comment on attachment 205289 [details] Patch for landing Clearing flags on attachment: 205289 Committed r151918: <http://trac.webkit.org/changeset/151918>
All reviewed patches have been landed. Closing bug.