TIP: Click on subject to list as thread! ANSI
echo: muffin
to: Bob Jones
from: Bo Simonsen
date: 2003-08-14 17:21:30
subject: QWK problem(s)

Hello Bob!

Wed 2003-08-13 09:39, Bob Jones (1:343/41) wrote to Bo Simonsen:

 BJ> === cut here ===
 BJ> 6. If he is declaring his own structures for reading squish  bases,
 BJ> you might find this syntax helpful:

 BJ> struct _mystruct
 BJ> {
 BJ>   int field;
 BJ> } __attribute__((packed));


 BJ> .that should give the same structure size as Scott was using on 
 BJ> the DOS-based compilers. Of course, __attribute__((a)) gets 
 BJ> #defined to spaces on non-__GNUC__ platforms..
 BJ> === cut here ===

 BJ> So, I would recommend checking to see if the structure you are
 BJ> using has the __attribute__((packed)); statement included.  If it
 BJ> does, then we had some padding under DOS / OS/2 / Win32 environment
 BJ> that wasn't clean in the old code.  If the attribute isn't there,
 BJ> then I'd try adding it for the structure being read and/or written
 BJ> in binary format to the qwk file....  Since I haven't looked at the
 BJ> specific code you're dealing with, this may not be the issue with
 BJ> the qwk code....

Wow it worked! :-)

Regards,
         Bo

--- timEd/Linux 1.11.b1
* 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™.