Index: content/browser/renderer_host/p2p/socket_host_tcp.cc |
diff --git a/content/browser/renderer_host/p2p/socket_host_tcp.cc b/content/browser/renderer_host/p2p/socket_host_tcp.cc |
index 250de53b5de10dcd3875fab77279754e1d9706d2..56d74a2fac4c052276813712a131664b59c3cc15 100644 |
--- a/content/browser/renderer_host/p2p/socket_host_tcp.cc |
+++ b/content/browser/renderer_host/p2p/socket_host_tcp.cc |
@@ -138,8 +138,7 @@ void P2PSocketHostTcp::OnPacket(std::vector<char>& data) { |
if (!authorized_) { |
P2PSocketHost::StunMessageType type; |
bool stun = GetStunPacketType(&*data.begin(), data.size(), &type); |
- if (stun && (type == STUN_BINDING_REQUEST || |
- type == STUN_BINDING_RESPONSE)) { |
+ if (stun && IsRequestOrResponse(type)) { |
Wez
2011/08/09 18:09:23
How does receipt of a binding/allocate request/res
Sergey Ulanov
2011/08/09 18:15:41
By sending/receiving the stun request or response
Wez
2011/08/09 18:30:57
The only effect that |authorized_| seems to have i
Sergey Ulanov
2011/08/09 19:18:26
We do block incoming data packets before stun requ
Wez
2011/08/09 19:54:50
Sorry; forgot about the |!authorized_| surrounding
Sergey Ulanov
2011/08/09 21:06:56
Ok, connected sounds good. I will rename it in a s
|
authorized_ = true; |
} else if (!stun || type == STUN_DATA_INDICATION) { |
LOG(ERROR) << "Received unexpected data packet from " |