Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(959)

Unified Diff: Source/core/inspector/InspectorResourceAgent.cpp

Issue 951313002: DevTools: NetworkPanel: Support unicode WS messages. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/inspector/InspectorResourceAgent.cpp
diff --git a/Source/core/inspector/InspectorResourceAgent.cpp b/Source/core/inspector/InspectorResourceAgent.cpp
index e5e509b6fa37bb9460be31405b4d6e20d3f38c30..20d9035d1f76fcd661693a7ce97c8fedd761ab78 100644
--- a/Source/core/inspector/InspectorResourceAgent.cpp
+++ b/Source/core/inspector/InspectorResourceAgent.cpp
@@ -764,7 +764,7 @@ void InspectorResourceAgent::didReceiveWebSocketFrame(unsigned long identifier,
RefPtr<TypeBuilder::Network::WebSocketFrame> frameObject = TypeBuilder::Network::WebSocketFrame::create()
.setOpcode(opCode)
.setMask(masked)
- .setPayloadData(String(payload, payloadLength));
+ .setPayloadData(String::fromUTF8WithLatin1Fallback(payload, payloadLength));
m_frontend->webSocketFrameReceived(IdentifiersFactory::requestId(identifier), currentTime(), frameObject);
}
@@ -773,7 +773,7 @@ void InspectorResourceAgent::didSendWebSocketFrame(unsigned long identifier, int
RefPtr<TypeBuilder::Network::WebSocketFrame> frameObject = TypeBuilder::Network::WebSocketFrame::create()
.setOpcode(opCode)
.setMask(masked)
- .setPayloadData(String(payload, payloadLength));
+ .setPayloadData(String::fromUTF8WithLatin1Fallback(payload, payloadLength));
m_frontend->webSocketFrameSent(IdentifiersFactory::requestId(identifier), currentTime(), frameObject);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698