aboutsummaryrefslogtreecommitdiff
path: root/src/netbase.h
diff options
context:
space:
mode:
authorCory Fields <cory-nospam-@coryfields.com>2017-09-18 18:45:51 -0400
committerCory Fields <cory-nospam-@coryfields.com>2017-12-12 15:25:25 -0500
commit1729c29dedc64d900a1a1c686a56e16fa5417fa1 (patch)
tree6eaab18b57cd1386e117381346b0de929c9319e0 /src/netbase.h
parent6f01dcf63873a5e42798635ab4026c9a5f9fa213 (diff)
downloadbitcoin-1729c29dedc64d900a1a1c686a56e16fa5417fa1.tar.xz
net: split socket creation out of connection
Also, check for the correct error during socket creation
Diffstat (limited to 'src/netbase.h')
-rw-r--r--src/netbase.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/netbase.h b/src/netbase.h
index e7d7bcb375..59945ea97d 100644
--- a/src/netbase.h
+++ b/src/netbase.h
@@ -51,6 +51,7 @@ bool Lookup(const char *pszName, CService& addr, int portDefault, bool fAllowLoo
bool Lookup(const char *pszName, std::vector<CService>& vAddr, int portDefault, bool fAllowLookup, unsigned int nMaxSolutions);
CService LookupNumeric(const char *pszName, int portDefault = 0);
bool LookupSubNet(const char *pszName, CSubNet& subnet);
+SOCKET CreateSocket(const CService &addrConnect);
bool ConnectSocketDirectly(const CService &addrConnect, SOCKET& hSocketRet, int nTimeout);
bool ConnectThroughProxy(const proxyType &proxy, const std::string& strDest, int port, SOCKET& hSocketRet, int nTimeout, bool *outProxyConnectionFailed);
/** Return readable error string for a network error code */