13 Commits (master)

Author SHA1 Message Date
Aadhavan Srinivasan 24b2a83044 Used a sockaddr_storage struct instead of a sockaddr struct, since the latter is not big enough for IPv6 1 year ago
Aadhavan Srinivasan 54f7dbe7ee Modified recvAllNB() to return an empty string (instead of NULL) if there is nothing to read 1 year ago
Aadhavan Srinivasan 4001135451 Integrated upstream changes, since I forgot to pull before making local changes. 1 year ago
Aadhavan Srinivasan 0058e7e411 Removed ip_ver parameter
I removed this because I realized I could just check the IP version inside
the constructor. The Sock constructor now checks the address passed to it.
Like before, if the address is neither v4 nor v6, an exception is thrown.
Since the Server and Client constructors call the Sock constructor, no change
was required in these files, except passing the right number of parameters.
1 year ago
Aadhavan Srinivasan 6acbf90d80 Updated UNIX macro checks, to account for MacOS 1 year ago
Aadhavan Srinivasan 64aa4b1850 Replaced 'linux' with '__unix__' because the same header files are included on macOS as well. 1 year ago
Aadhavan Srinivasan 8e3488b904 Added a virtual destructor to the Sock class, which would allow Server and Client to override it 1 year ago
Aadhavan Srinivasan 4b3d5387a1 Changed code to support Windows libraries and functions as well 1 year ago
Aadhavan Srinivasan a37ec79f09 Changed 'recvAll' return type from std::string to char pointer, and created a non-blocking version of the function 1 year ago
Aadhavan Srinivasan f0e30f28e9 Updated header files to reflect recent change in implementation files 1 year ago
Aadhavan Srinivasan cacc4f9d33 Included string header instead of iostream header, as this file doesn't need iostream 1 year ago
Aadhavan Srinivasan 195d6c4b4b Separated 'Sock' file into header and implementation file, and added include guards to header file 1 year ago
Aadhavan Srinivasan 2e6b01a9bb Defined a parent 'socket' class that both 'Client' and 'Server' can inherit from 1 year ago