ralphjzhang / openpgm

Automatically exported from code.google.com/p/openpgm
0 stars 0 forks source link

Porting to FreeBSD #2

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I've been playing with porting this to FreeBSD 8.0 amd64 kernel.  So far
have managed to get libraries and pgmsend & pgmrecv to compile & start.

One thing I noticed was that there is a line in packet.c (~ line 200)
     gsize packet_length = g_ntohs(ip->ip_len); /*   total packet length */

From what I can tell the ip->ip_len is set from the recvmsg call in recv.c
line 197, and is already in host order.  This call then inverts the length.
Should this line actually be:

        gsize packet_length = ip->ip_len;       /* MJ: this is set by the
recv call, which returns in host order - not sure why it was different! see
recv.c:197*/

(This works on my build, but I'm not anywhere near an expert!)

Original issue reported on code.google.com by 7char...@gmail.com on 28 Mar 2010 at 10:46

GoogleCodeExporter commented 9 years ago
FreeBSD 8.0 is supported in OpenPGM 3 and 5.

The ordering is configurable with CONFIG_HOST_ORDER_IP_LEN added in r976.

Original comment by fnjo...@gmail.com on 3 Jul 2010 at 5:42