Status: New
Owner: ----

New issue 2167 by [email protected]: messing with XMLHttpRequest.prototype.open makes chrome unstable
http://code.google.com/p/v8/issues/detail?id=2167

//Google Chrome version 19.0.1084.52 m on windows 7 x64
//The following code is for disallowing XMLHttpRequest to connect to facebook.com/ajax/mercury/change_read_status.php, when on facebook.com //Code: works as expected in firefox. (eg, friends cannot see if you have seen their messages or not, ref: http://nickcicero.files.wordpress.com/2012/05/screen-shot-2012-05-25-at-10-49-17-am.png ) //while it makes chrome window unresponding, un-closable (cannot X-it-out at all, need to use taskkill/taskmanager), and sometimes, completely white (when url.toString().indexOf('change_read_status')!=-1 ) //i have tried just returning. i have tried altering the url. tried throwing exception, and they all lead to the same result in chrome.
//(and no exception is seen in chrome console.)

XMLHttpRequest.prototype.originalOpen = XMLHttpRequest.prototype.open;
XMLHttpRequest.prototype.open = function(/*DOMString */method,/* DOMString */url,/* optional boolean */async,/* optional DOMString? */user,/* optional DOMString? */password)
{//ty https://developer.mozilla.org/en/DOM/XMLHttpRequest#open%28%29
if(url.toString().indexOf('change_read_status')!=-1)
{
throw "sorry exception";
return;
url='http://httpstat.us/200/';
//alert("should block this!");
//method="GET";
}
/*return void*/this.originalOpen(method,url,async,user,password);
}


also note that i have tried creating a "minimum code to reproduce" (in a standalone html file), without any luck.. (this does not reproduce the error: http://havbakeriet.no/hans/test/crashchrome.php ), but im not a expert either

--
v8-dev mailing list
[email protected]
http://groups.google.com/group/v8-dev

Reply via email to