Thanks for providing this useful tool
I have made two enhancements to this program :
1) bind the connecting socket to the same IP address as the listen one in order to use the same interface (otherwise, no control on the interface used for connect)
2) made support of name resolution optional (-n option) ; in my case, it decreases the performance, and display unaccurate info (interrogate internet, while I use testing addresses / ports) ; name resolution attempt is not desirable in a testing / closed environment without dns
I don't know if maintenance is still active ; anyway, I join the modified file
Brgds
Modified file