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

Side by Side Diff: Source/modules/websockets/MainThreadWebSocketChannel.cpp

Issue 14247036: Remove USE(ZLIB) guard. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Rebase Created 7 years, 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | Source/modules/websockets/WebSocketDeflateFramer.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2011, 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after
95 { 95 {
96 } 96 }
97 97
98 void MainThreadWebSocketChannel::connect(const KURL& url, const String& protocol ) 98 void MainThreadWebSocketChannel::connect(const KURL& url, const String& protocol )
99 { 99 {
100 LOG(Network, "MainThreadWebSocketChannel %p connect()", this); 100 LOG(Network, "MainThreadWebSocketChannel %p connect()", this);
101 ASSERT(!m_handle); 101 ASSERT(!m_handle);
102 ASSERT(!m_suspended); 102 ASSERT(!m_suspended);
103 m_handshake = adoptPtr(new WebSocketHandshake(url, protocol, m_document)); 103 m_handshake = adoptPtr(new WebSocketHandshake(url, protocol, m_document));
104 m_handshake->reset(); 104 m_handshake->reset();
105 if (m_deflateFramer.canDeflate()) 105 m_handshake->addExtensionProcessor(m_deflateFramer.createExtensionProcessor( ));
106 m_handshake->addExtensionProcessor(m_deflateFramer.createExtensionProces sor());
107 if (m_identifier) 106 if (m_identifier)
108 InspectorInstrumentation::didCreateWebSocket(m_document, m_identifier, u rl, m_document->url(), protocol); 107 InspectorInstrumentation::didCreateWebSocket(m_document, m_identifier, u rl, m_document->url(), protocol);
109 ref(); 108 ref();
110 m_handle = SocketStreamHandle::create(m_handshake->url(), this); 109 m_handle = SocketStreamHandle::create(m_handshake->url(), this);
111 } 110 }
112 111
113 String MainThreadWebSocketChannel::subprotocol() 112 String MainThreadWebSocketChannel::subprotocol()
114 { 113 {
115 LOG(Network, "MainThreadWebSocketChannel %p subprotocol()", this); 114 LOG(Network, "MainThreadWebSocketChannel %p subprotocol()", this);
116 if (!m_handshake || m_handshake->mode() != WebSocketHandshake::Connected) 115 if (!m_handshake || m_handshake->mode() != WebSocketHandshake::Connected)
(...skipping 674 matching lines...) Expand 10 before | Expand all | Expand 10 after
791 return false; 790 return false;
792 } 791 }
793 792
794 Vector<char> frameData; 793 Vector<char> frameData;
795 frame.makeFrameData(frameData); 794 frame.makeFrameData(frameData);
796 795
797 return m_handle->send(frameData.data(), frameData.size()); 796 return m_handle->send(frameData.data(), frameData.size());
798 } 797 }
799 798
800 } // namespace WebCore 799 } // namespace WebCore
OLDNEW
« no previous file with comments | « no previous file | Source/modules/websockets/WebSocketDeflateFramer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698