summaryrefslogtreecommitdiff
path: root/socketft.h
diff options
context:
space:
mode:
authorJeffrey Walton <noloader@gmail.com>2017-03-01 06:10:06 -0500
committerJeffrey Walton <noloader@gmail.com>2017-03-01 06:10:06 -0500
commit5efb019d8bdc593b3c1a0b57d615b170c7dab02a (patch)
treee2c10e737542fd13ea50b58480e0791bbc455e47 /socketft.h
parent5fb2f5d45b9bb2cd86db5d01f4b30d606a2a4c80 (diff)
downloadcryptopp-git-5efb019d8bdc593b3c1a0b57d615b170c7dab02a.tar.gz
Add C++ nullptr support (Issue 383)
Diffstat (limited to 'socketft.h')
-rw-r--r--socketft.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/socketft.h b/socketft.h
index 0fefb65c..c9942d8e 100644
--- a/socketft.h
+++ b/socketft.h
@@ -70,14 +70,14 @@ public:
void CloseSocket();
void Create(int nType = SOCK_STREAM);
- void Bind(unsigned int port, const char *addr=NULL);
+ void Bind(unsigned int port, const char *addr=NULLPTR);
void Bind(const sockaddr* psa, socklen_t saLen);
void Listen(int backlog = SOMAXCONN);
// the next three functions return false if the socket is in nonblocking mode
// and the operation cannot be completed immediately
bool Connect(const char *addr, unsigned int port);
bool Connect(const sockaddr* psa, socklen_t saLen);
- bool Accept(Socket& s, sockaddr *psa=NULL, socklen_t *psaLen=NULL);
+ bool Accept(Socket& s, sockaddr *psa=NULLPTR, socklen_t *psaLen=NULLPTR);
void GetSockName(sockaddr *psa, socklen_t *psaLen);
void GetPeerName(sockaddr *psa, socklen_t *psaLen);
unsigned int Send(const byte* buf, size_t bufLen, int flags=0);
@@ -194,7 +194,7 @@ private:
class SocketSource : public NetworkSource, public Socket
{
public:
- SocketSource(socket_t s = INVALID_SOCKET, bool pumpAll = false, BufferedTransformation *attachment = NULL)
+ SocketSource(socket_t s = INVALID_SOCKET, bool pumpAll = false, BufferedTransformation *attachment = NULLPTR)
: NetworkSource(attachment), Socket(s), m_receiver(*this)
{
if (pumpAll)