This is a small socket library I made to avoid complicated C
C boilerplate code and several #includes
for connecting sockets, bind, listening etc.
Please note that socket_create()
does not support bind
to specific IP address.addresses and that the IP parameter is ignored.
The only C++11
C++11 feature I am using is constexpr
.
Even though it is C++11
C++11, I decided not to wrap everything in a class, but to work with standard int
.
In the future, I might add unix domain socket
Unix domain socket in a way similar to socket_create()
and / or SSL support, but at the moment I do not need those.
#sockets.hsockets.h
#sockets.ccsockets.cc