| TIP: Click on subject to list as thread! | ANSI |
| echo: | |
|---|---|
| to: | |
| from: | |
| date: | |
| subject: | Re: Big endian machines |
PS> Hi Bo! :-)
Hi Pascal,
BS> I'm looking into this issue because it looks like
BS> that SquishMail has
BS> problems my reading a packed (__attribute__(packed)) structure from
BS> diskfile written on a little endian machine.
PS> No guesses please, show us the structure definition. :)
It would be no-sence to show you the whole structure, so here's just a bit
of it:
struct _pkthdr
{
sword orig_node; /* originating node */
sword dest_node; /* destination node */
} __attribute__((packed, aligned(2)));
The structure contains most words and a couple of bytes.
It's beeing readed by
read(fp, &pkthdr, sizeof(struct _pkthdr));
Should I read every single variable in the structure to get it working?
Bo
--- Maximus/UNIX 3.03b
* Origin: The Night Express - Roennede, Dk (2:236/100)SEEN-BY: 633/267 270 @PATH: 236/100 237/9 20/11 106/1 2000 633/267 |
|
| SOURCE: echomail via fidonet.ozzmosis.com | |
Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.