W3C home > Mailing lists > Public > public-webapps@w3.org > January to March 2011

Re: [chromium-html5] LocalStorage inside Worker

From: Felix Halim <felix.halim@gmail.com>
Date: Thu, 27 Jan 2011 16:39:15 +0800
Message-ID: <AANLkTik3Un_j8=z0hEo-j1Xs-EubBG=p66GPCFNhW+17@mail.gmail.com>
To: Jonas Sicking <jonas@sicking.cc>
Cc: Boris Zbarsky <bzbarsky@mit.edu>, Joćo Eiras <joao.eiras@gmail.com>, public-webapps WG <public-webapps@w3.org>
2011/1/7 Jonas Sicking <jonas@sicking.cc>:
> On Thu, Jan 6, 2011 at 7:14 PM, Boris Zbarsky <bzbarsky@mit.edu> wrote:
>> On 1/6/11 5:25 PM, Joćo Eiras wrote:
>>>
>>> Not different from two different tabs/windows running the same code.
>>
>> In which current browsers do same-origin tabs/windows end up interleaving
>> their JS (that is, one runs JS before the other has returned to the event
>> loop)?
>
> I'm fairly sure it happens both in Chrome and IE. One way it can happen is:
>
> Tab 1 opens with a page from site A
> Tab 2 opens with a page from site B
> The page in tab 2 contains an iframe with a page from site A.
>
> But I'm not even sure that Chrome and IE makes an effort to use the
> same process if you open two tabs for the same site.

It seemed that Chrome doesn't interleave the JS when the same page is
opened in multiple tabs.

Try running this script in multiple tabs and monitor the console output:

http://felix-halim.net/interleave.html

In Chrome console log, you will see many "FAIL", but not in Firefox.

So does this mean localStorage in Chrome is broken? or this is an
intended behavior?


Felix Halim
Received on Thursday, 27 January 2011 08:39:52 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 18:49:43 GMT