0
votes

I'm trying to simulate WSAEWOULDBLOCK on blocking send() with setsockopt by reducing the internal Winsock send buffer to a very small value and 2 threads sending at same time...

Droping the connection by unplug the network cable or block it in the firewall is not sufficient to fill up the internal send buffer and return the WSAEWOULDBLOCK ?

How can I do this ?

Thank's.

1

1 Answers

1
votes

Accept the connection on the remote end, but tarpit at that location. Keep trying to send on the local end, and you should be able to fill up the data buffer used for outgoing traffic.