On Jan 27, 2014, at 12:33 PM, Eduard Gibert Renart <edugib...@gmail.com> wrote:
> Yes my architecture is little-endian. So I need to convert the length and
> the xid like this ?
>
> struct ofp_header header;
> header.version = OFP_VERSION;
> header.type = OFPT_HELLO;
> header.length = htons(8);
> header.xid = htonl(13);
yes. I haven't tested your code, but the incorrect length could definitely be
the problem (xid not so much). try it and see!
if you are new to htons and htonl, I suggest this description:
http://www.beej.us/guide/bgnet/output/html/multipage/ipstructsdata.html#byteorder
from the excellent Beej's Guide to Network Programming, which I also recommend:
http://www.beej.us/guide/bgnet/
Andrew
_______________________________________________
openflow-discuss mailing list
openflow-discuss@lists.stanford.edu
https://mailman.stanford.edu/mailman/listinfo/openflow-discuss