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

Unified Diff: remoting/protocol/jingle_session.h

Issue 9447087: Revert 123635 - Implement timeouts for IQ requests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 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 | « remoting/protocol/jingle_messages.cc ('k') | remoting/protocol/jingle_session.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/jingle_session.h
===================================================================
--- remoting/protocol/jingle_session.h (revision 123637)
+++ remoting/protocol/jingle_session.h (working copy)
@@ -13,7 +13,6 @@
#include "base/timer.h"
#include "crypto/rsa_private_key.h"
#include "net/base/completion_callback.h"
-#include "remoting/jingle_glue/iq_sender.h"
#include "remoting/protocol/authenticator.h"
#include "remoting/protocol/jingle_messages.h"
#include "remoting/protocol/session.h"
@@ -26,6 +25,9 @@
} // namespace net
namespace remoting {
+
+class IqRequest;
+
namespace protocol {
class JingleSessionManager;
@@ -84,15 +86,8 @@
scoped_ptr<Authenticator> authenticator);
void AcceptIncomingConnection(const JingleMessage& initiate_message);
- // Helper to send IqRequests to the peer. It sets up the response
- // callback to OnMessageResponse() which simply terminates the
- // session whenever a request fails or times out. This method should
- // not be used for messages that need to be handled differently.
- void SendMessage(const JingleMessage& message);
- void OnMessageResponse(JingleMessage::ActionType request_type,
- IqRequest* request,
- const buzz::XmlElement* response);
- void CleanupPendingRequests(IqRequest* request);
+ // Handler for session-initiate response.
+ void OnSessionInitiateResponse(const buzz::XmlElement* response);
// Called by JingleSessionManager on incoming |message|. Must call
// |reply_callback| to send reply message before sending any other
@@ -113,8 +108,10 @@
bool InitializeConfigFromDescription(const ContentDescription* description);
void ProcessAuthenticationStep();
+ void OnSessionInfoResponse(const buzz::XmlElement* response);
void SendTransportInfo();
+ void OnTransportInfoResponse(const buzz::XmlElement* response);
// Terminates the session and sends session-terminate if it is
// necessary. |error| specifies the error code in case when the
@@ -139,10 +136,9 @@
scoped_ptr<Authenticator> authenticator_;
- // Container for pending Iq requests. Requests are removed in
- // CleanupPendingRequests() which is called when a response is
- // received or one of the requests times out.
- std::list<IqRequest*> pending_requests_;
+ scoped_ptr<IqRequest> initiate_request_;
+ scoped_ptr<IqRequest> session_info_request_;
+ scoped_ptr<IqRequest> transport_info_request_;
ChannelsMap channels_;
« no previous file with comments | « remoting/protocol/jingle_messages.cc ('k') | remoting/protocol/jingle_session.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698