Article View: comp.lang.c.moderated
Article #2462Re: void* type
From: msb
Date: Tue, 02 Apr 1996 02:00
Date: Tue, 02 Apr 1996 02:00
17 lines
1343 bytes
1343 bytes
> > The realloc can certainly do something like use sz+10000 > > to "grow" the tmp area in tunable chunks, depending on the application. > > Better yet: unless memory is really tight, have it double the size. > This will set a fairly reasonable upper bound on the number of reallocs > you will have to do. Better yet: change "unless memory is really tight" to "if memory is plentiful". The doubling method can run out of memory when the amount available is almost twice the amount that you need, not even considering the possibility of fragmentation. -- Mark Brader "I always pass on good advice. It's the only thing msb@sq.com to do with it. It is never any use to oneself." SoftQuad Inc., Toronto -- Lord Goring (Oscar Wilde: An Ideal Husband) My text in this article is in the public domain.
Technical Details
Message-ID:
<4jq1o1$a8v@solutions.solon.com>Path:
arc1-ca.pugleaf.net!solon.com!not-for-mailReferences:
<4iepre$ag7@solutions.solon.com> <4jckqc$a5o@solutions.solon.com> <4jibl5$89u@solutions.solon.com> <4jol6e$1rr@solutions.solon.com>Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!solon.com!not-for-mail From: msb@sq.com Newsgroups: comp.lang.c.moderated Subject: Re: void* type Date: 1 Apr 1996 20:00:33 -0600 Organization: SoftQuad Inc., Toronto, Canada Sender: clc@solutions.solon.com Approved: clc@solutions.solon.com Message-ID: <4jq1o1$a8v@solutions.solon.com> References: <4iepre$ag7@solutions.solon.com> <4jckqc$a5o@solutions.solon.com> <4jibl5$89u@solutions.solon.com> <4jol6e$1rr@solutions.solon.com> NNTP-Posting-Host: solutions.solon.com