[webkit-reviews] review granted: [Bug 43643] Detect invalid CoreIPC messages and call didReceiveInvalidMessage : [Attachment 63761] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Fri Aug 6 14:44:25 PDT 2010
Adam Roben (aroben) <aroben at apple.com> has granted Anders Carlsson
<andersca at apple.com>'s request for review:
Bug 43643: Detect invalid CoreIPC messages and call didReceiveInvalidMessage
https://bugs.webkit.org/show_bug.cgi?id=43643
Attachment 63761: Patch
https://bugs.webkit.org/attachment.cgi?id=63761&action=review
------- Additional Comments from Adam Roben (aroben) <aroben at apple.com>
> @@ -253,14 +257,15 @@ void Connection::dispatchMessages()
> OwnPtr<ArgumentEncoder> replyEncoder(new
ArgumentEncoder(syncRequestID));
>
> // Hand off both the decoder and encoder to the client..
> - m_client->didReceiveSyncMessage(this, message.messageID(),
arguments, replyEncoder.get());
> + m_client->didReceiveSyncMessage(this, message.messageID(),
arguments.get(), replyEncoder.get());
>
> // Send the reply.
> sendMessage(MessageID(CoreIPCMessage::SyncMessageReply),
replyEncoder.release());
> } else
> - m_client->didReceiveMessage(this, message.messageID(),
arguments);
> + m_client->didReceiveMessage(this, message.messageID(),
arguments.get());
>
> - message.destroy();
> + if (arguments->isInvalid())
> + m_client->didReceiveInvalidMessage(this, message.messageID());
> }
> }
Should we check if the arguments are invalid before sending the synchronous
reply?
r=me
More information about the webkit-reviews
mailing list