🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.os.msdos.programmer
Article #7870

Re: What is the max mem returned by `malloc`?

#7870
From: Laurence Mee
Date: Tue, 05 Sep 1995 12:03
28 lines
1698 bytes
In article <42f680$dlj@caip.rutgers.edu> halasz@caip.rutgers.edu  writes:

> In article <42daou$n8h@tuzo.erin>, cfranzin@erin.utoronto.ca (Carla Maria
>  Franzin) writes
> > ... 
> >  What does the C language define for the maximum memory that malloc 
> > returns? The reason I ask is because of Dos 32-bit flat memory problems I 
> > have. I'm not seeing why you might want to make a singulaly linked list 
> > of say 16k?
> 
> As far as I know, none at all and the standard leavs this implementational.
> Therefore, you hav little choice but to rede your vendor s writ or ask in
> other newsgroups, as I hav set.
> 

malloc can return up to the maximum available free memory for the compiled
model - well that's not quite true as memory can get fragmented occasionally!
Thus for flat model malloc can return up to the maximum amount of memory
addressed by the extender - thus you can malloc megabytes in one call!

-- 
See Ya!
    Laurence.

------------------------------------------------
The benefit of being stubborn is that you always
know what you are going to be thinking tomorrow!
------------------------------------------------
Technical Details
Message-ID: <810302621snz@wyrm.demon.co.uk>
Path: arc1-ca.pugleaf.net!mail2news.demon.co.uk!wyrm.demon.co.uk
References: <42daou$n8h@tuzo.erin> <42f680$dlj@caip.rutgers.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!mail2news.demon.co.uk!wyrm.demon.co.uk
From: Laurence Mee <laurence@wyrm.demon.co.uk>
Newsgroups: comp.os.msdos.programmer,comp.lang.c
Subject: Re: What is the max mem returned by `malloc`?
Date: Tue, 05 Sep 95 12:03:41 GMT
Organization: The FLIGHT DATA Company
Distribution: can
Message-ID: <810302621snz@wyrm.demon.co.uk>
References: <42daou$n8h@tuzo.erin> <42f680$dlj@caip.rutgers.edu>
Reply-To: laurence@wyrm.demon.co.uk
X-NNTP-Posting-Host: wyrm.demon.co.uk
X-Newsreader: Demon Internet Simple News v1.29