|
the BSD socket interface (or their derivative, Winsock) does not allow you to choose the outgoing IP or interface for connect(). It is up to the OS to choose the best route. There may be system-specific ways of doing this (perhaps some ioctl supported on your OS), but there is no general solution.
|