Bug 85346 - EventSource: Events should not be dispatched after close()
Summary: EventSource: Events should not be dispatched after close()
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-05-01 21:58 PDT by Yuta Kitamura
Modified: 2012-06-25 17:00 PDT (History)
7 users (show)

See Also:


Attachments
Patch (4.60 KB, patch)
2012-05-11 14:58 PDT, Pablo Flouret
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yuta Kitamura 2012-05-01 21:58:40 PDT
Original report: http://code.google.com/p/chromium/issues/detail?id=125190

Reported by VMuhachev, Apr 26 (5 days ago)
    After EventSource#close() method is called, no events should be fired and 
    readyState attribute should stay equal to EventSource.CLOSED
    See: http://html5.org/tools/web-apps-tracker?from=6771&to=6772 ,
         https://www.w3.org/Bugs/Public/show_bug.cgi?id=14331#c5

event-stream:
    :text/event-stream
    data: data0;
    
    
    data: data1;
    
    
    var es = new EventSource('...');
    var counter = 0;
    es.onmessage = function () {
      counter += 1;
      if (counter > 1) {
        alert('bug!');
      }
      es.close();
    };
Comment 1 Pablo Flouret 2012-05-11 14:58:44 PDT
Created attachment 141501 [details]
Patch
Comment 2 Pablo Flouret 2012-06-11 15:00:42 PDT
Ping?
Comment 3 WebKit Review Bot 2012-06-25 17:00:13 PDT
Comment on attachment 141501 [details]
Patch

Clearing flags on attachment: 141501

Committed r121195: <http://trac.webkit.org/changeset/121195>
Comment 4 WebKit Review Bot 2012-06-25 17:00:26 PDT
All reviewed patches have been landed.  Closing bug.