[Webkit-unassigned] [Bug 25043] Race condition in MessagePort::clone()

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jun 16 16:18:31 PDT 2009


https://bugs.webkit.org/show_bug.cgi?id=25043





------- Comment #6 from levin at chromium.org  2009-06-16 16:18 PDT -------
> tryGetMessageFromRemote(RefPtr<MessagePortProxyWrapper::EventData>& result)
s/result/message/

In MessagePort.cpp, it is odd that m_queueIsOpen is not set to false after
MessagePort::close is called.  Perhaps it should have a different name:
m_started?  or even better m_enabled? (which is terminology from the spec).


Other minor very minor nits:
In LayoutTests/fast/events/message-port-clone.html-disabled:
* it would be good to add periods to your comments (in log messages too).
* it switches from indenting by 4 to indenting by 2 spaces.  
* the formatting for things like "channel.port2.onmessage = function(evt)" is
inconsistent.  (Sometimes you put the { at the end of the line and sometimes at
the beginning of the next line.  I've seen both in these js files.  It seems
like at the beginning of the next line is more consistent with WebKit in
general.)
* var msgIndex = 1;  I'd change it to messageIndex to avoid abbreviations.


General style:
1. Blank line between functions.
2. No blank line after public:, private: but one blank line before them when
they are in the middle of the class.

Following these:
Before void MessagePort::contextDestroyed(), there is an extra blank line.
In class MessagePortProxyWrapper, there is an extra blank line after public:
In class MessagePortProxyWrapper::EventData, it would be nice to add a blank
line before private:
In class MessagePortProxy::MessagePortQueue, it would be nice to add a blank
line before private:

In class MessagePortProxy::MessagePortQueue, the "inline" before each function
defined in the class is redundant, so I'd just remove it.

So far the functionality looks great.  I'm almost done.


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list