At Tue, 04 Mar 2025 06:37:56 +0000, Lars Brinkhoff <lars(a)nocrew.org> wrote:
Subject: [TUHS] Re: Any UNIX With No C In Userland?
I NEVER EVER use C structs or bit fields for this. I get the raw octets
(or whatever the byte size is), and shift and mask accordingly to get
the data fields.
Marshalling data in or out byte by byte is of course safe and is
definitely the most portable way, and one can of course still read or
write "record"-length amounts of bytes at one time (or multiples of
records). It just can be a little more tedious.
--
Greg A. Woods <gwoods(a)acm.org>
Kelowna, BC +1 250 762-7675 RoboHack <woods(a)robohack.ca>
Planix, Inc. <woods(a)planix.com> Avoncote Farms <woods(a)avoncote.ca>