|
Re: socket bind and prefix
|
10/31/2008 8:58 AM
post15785
|
Re: socket bind and prefix
On Fri, Oct 31, 2008 at 05:25:05AM -0400, Thomas Zauner wrote:
> Thanks, Sean and Robert.
> My problem is: The system is equipped by my customer. They installed both io-net and io-pkt for the 2 network cards,
as they did not get both adapters to run with io-pkt. I want to do UDP communication with the first adapter, and pcap
with the second. If I specify SOCK, I can access only one adapter in my program.
> Is it possible for a program to access 2 stacks at a time, or should my custerms try to set up io-pkt correctly for
the 2 adapters?
It's possible. You'd have to clearenv(), setenv() SOCK as
required before each socket() call to target a particular
stack. Or you could get a seed socket for each stack once
via the SOCK method, leave it open and do openfd() on them
as required which will get you a socket of the same domain,
type, protocol as the seed managed by the same stack.
-seanb
|
|
|