Index: chrome/browser/extensions/api/messaging/message_service.h |
diff --git a/chrome/browser/extensions/api/messaging/message_service.h b/chrome/browser/extensions/api/messaging/message_service.h |
index fa641f3be4af19e884d68bae9443c5256459e1e3..08e0c5970f6579d2c2b36e3851ab4907df689534 100644 |
--- a/chrome/browser/extensions/api/messaging/message_service.h |
+++ b/chrome/browser/extensions/api/messaging/message_service.h |
@@ -185,7 +185,7 @@ class MessageService : public BrowserContextKeyedAPI { |
struct OpenChannelParams; |
// A map of channel ID to its channel object. |
- typedef std::map<int, MessageChannel*> MessageChannelMap; |
+ typedef std::map<int, std::unique_ptr<MessageChannel>> MessageChannelMap; |
Devlin
2016/09/16 20:23:19
nit: update to 'using' syntax since we're here?
Avi (use Gerrit)
2016/09/16 20:41:45
Done.
|
typedef std::pair<int, Message> PendingMessage; |
typedef std::vector<PendingMessage> PendingMessagesQueue; |
@@ -226,7 +226,8 @@ class MessageService : public BrowserContextKeyedAPI { |
// Have MessageService take ownership of |channel|, and remove any pending |
// channels with the same id. |
- void AddChannel(MessageChannel* channel, int receiver_port_id); |
+ void AddChannel(std::unique_ptr<MessageChannel> channel, |
+ int receiver_port_id); |
// If the channel is being opened from an incognito tab the user must allow |
// the connection. |