From: Moo-Juice Newsgroups: comp.os.msdos.djgpp Subject: Re: Dynamic Arrays Date: Fri, 24 Jan 1997 10:50:36 +0000 Organization: Honest Ron's Car Emporium Lines: 17 Distribution: world Message-ID: References: <01bc072e$33eb9b20$ee038cd0 AT wahander> <32E453A2 DOT FA3 AT cs DOT com> NNTP-Posting-Host: flag.demon.co.uk MIME-Version: 1.0 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp In article <32E453A2 DOT FA3 AT cs DOT com>, "John M. Aldrich" writes >Josh Anderson wrote: >> >> I know this is a stupid question, but how do you create a dynamic array of >> a bunch of structs? I only need to set the size of the array at init time. >> And then free the memory at exit. >If you want to make the entire list dynamic, i.e.; its size can change >during runtime, then you need a much more complex algorithm, but again >it's something that's in every C textbook I've ever seen. If you really >still need help, email me in private and I'll send you more samples. Surely simply using a realloc will suffice? -- Moo-Juice