Xref: utzoo comp.sys.ibm.pc:30427 comp.lang.c:19515 alt.msdos.programmer:143 Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!rutgers!mailrus!shadooby!accuvax.nwu.edu!tank!eecae!cps3xx!usenet From: usenet@cps3xx.UUCP (Usenet file owner) Newsgroups: comp.sys.ibm.pc,comp.lang.c,alt.msdos.programmer Subject: Re: Trouble readn' and writn' in C Message-ID: <3504@cps3xx.UUCP> Date: 21 Jun 89 20:32:33 GMT References: <3037@csd4.milw.wisc.edu> Distribution: na Organization: Engineering, Michigan State U., E. Lansing MI Lines: 14 in article <3037@csd4.milw.wisc.edu>, mag2@csd4.milw.wisc.edu (Michael A Gorski) says: $ I am writing a program in Turbo C 1.5 and am having trouble writing $ structures to a disk file. $ When I just do a DOS type file (yes I know it isn't a text file) the char $ fields in the struct are off by 1. Sounds like problems with word aligned data when you want byte aligned data. Check the manual, there should be a compile line option to control this. John H. Lawitzke UUCP: Work: ...uunet!frith!dale1!jhl Dale Computer Corp., R&D Home ...uunet!frith!ipecac!jhl 2367 Science Parkway Internet: jhl@frith.egr.msu.edu Okemos, MI, 48864 [35.8.8.108]