The issue is that not all computers use the same endian- wikipedia would have a great explanation I'm sure.<div><br></div><div>Any data type which is greater than 1 byte will need to be in the correct byte order. A char is just one byte, so every computer would read that the same way, but a typical int is 4 bytes hence big and little endian computers would store them differently.</div>
<div><br></div><div>I hope this sufficiently answers your question.<br><br><div class="gmail_quote">On Mon, Jan 26, 2009 at 11:07 AM, Andrew Fenn <span dir="ltr"><<a href="mailto:andrewfenn@gmail.com">andrewfenn@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">On Mon, Jan 26, 2009 at 3:08 PM, Mark Palkow <<a href="mailto:palkow@daviko.com">palkow@daviko.com</a>> wrote:<br>
> Is "strcat" the right thing?<br>
> I would try "strcpy" instead.<br>
<br>
Hurray, it works. One more question if you don't mind.<br>
<br>
I was reading in the mailing list that one should use the POSH library<br>
to convert all data to big endian before transmitting. This is done so<br>
that if one transmits from Mac -> Windows -> Linux the data doesn't<br>
end up as garbage. Is this correct? What data needs converting, just<br>
int and float not char?<br>
<br>
Sorry for all the silly questions.<br>
<br>
Thanks,<br>
Andrew<br>
_______________________________________________<br>
ENet-discuss mailing list<br>
<a href="mailto:ENet-discuss@cubik.org">ENet-discuss@cubik.org</a><br>
<a href="http://lists.cubik.org/mailman/listinfo/enet-discuss" target="_blank">http://lists.cubik.org/mailman/listinfo/enet-discuss</a><br>
</blockquote></div><br><br clear="all"><br>-- <br>aaron r andersen<br>tel: (647) 377-0401<br>e-mail: <a href="mailto:aaron.r.andersen@gmail.com">aaron.r.andersen@gmail.com</a><br>
</div>