We had a fully functional ready to submit program using UDP sendto() (well before submission deadline i might add).<br><br>We
are under the impression that MNL sendto() is supposed to be a
transparent function such that we can replace all of our UDP sendto()s
with MNL sendto()s.
<br><br>This is not the case.<br><br>In an attempt to prepare for the
HTTP client/server early on, our implementation involves a listening
port on the receiver that sets up pairs of sockets on either side.&nbsp;
(one for outgoing, one for incoming data - these were meant to be used
for data transfer in HTTP transactions)
<br><br>We connected the sockets on either end, and our UDP sendto() calls look like this:<br><br>&nbsp;&nbsp; sendto(node-&gt;out_fd, &amp;s_header, S_HSIZE, 0, NULL, sizeof blankAddr);<br><br>Our MNL sendto() calls look like this:
<br><br>&nbsp; MNL_sendto(node-&gt;out_fd, &amp;s_header, S_HSIZE, 0, serv_addr, length, node-&gt;seqNumber, 0, S_HSIZE, &amp;error);<br><br><br>(serv_addr is allready struct sockaddr pointer, error is a local variable, etc. (basically our arguments are valid))
<br><br>When we replaced our UDP sends with MNL sends, the MNL daemons
said that the packets were getting sent to the appropriate sockets, but
in reality the packets were not making it.<br>It seemed that MNL
sentto() only worked between the initial sender socket and receiver
listening port. As soon as the receiver handed over the job to the
other specially created sockets/ports MNL sentto() stopped working,
although UDP sendto() does.
<br><br>We were wondering if MNL sendto() can only support 1
connection - Or transfer between only 2 sockets.&nbsp; As in if you send
from one socket to another.&nbsp; And then from the same socket to a
DIFFERENT one, will MNL fail? because in our case it sure seems like it
does.
<br><br>Any ideas?<br><br>Thanks.