summaryrefslogtreecommitdiff
path: root/src/AbstractCommand.h
diff options
context:
space:
mode:
authorTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2013-04-01 00:12:27 +0900
committerTatsuhiro Tsujikawa <tatsuhiro.t@gmail.com>2013-04-01 00:12:27 +0900
commit597e1a5c1b10aa3668f91bcae02a864dcd0c045b (patch)
tree4437c2896b410b441013452b7385dfa303441772 /src/AbstractCommand.h
parentd671d8bf3672cbefc06f3727f82b77872abe6120 (diff)
Implement simple Happy Eyeballs for HTTP/FTP downloads
Diffstat (limited to 'src/AbstractCommand.h')
-rw-r--r--src/AbstractCommand.h12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/AbstractCommand.h b/src/AbstractCommand.h
index 53676077..d0749aa7 100644
--- a/src/AbstractCommand.h
+++ b/src/AbstractCommand.h
@@ -123,6 +123,11 @@ protected:
return socket_;
}
+ SharedHandle<SocketCore>& getSocket()
+ {
+ return socket_;
+ }
+
void setSocket(const SharedHandle<SocketCore>& s);
void createSocket();
@@ -215,6 +220,13 @@ protected:
}
void checkSocketRecvBuffer();
+
+ // Returns true if the derived class wants to execute
+ // executeInternal() unconditionally
+ virtual bool noCheck()
+ {
+ return false;
+ }
public:
AbstractCommand
(cuid_t cuid, const SharedHandle<Request>& req,