www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/02/19/05:33:34

Message-ID: <005801be5bcb$307e60f0$2bfba0cc@hclt.com>
From: "Kannan. S" <kannans AT indus DOT hclt DOT com>
To: <djgpp AT delorie DOT com>
Subject: Re: free RAM available
Date: Fri, 19 Feb 1999 11:16:25 +0530
MIME-Version: 1.0
X-Priority: 3
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook Express 5.00.0810.800
X-MimeOLE: Produced By Microsoft MimeOLE V5.00.0810.800
Reply-To: djgpp AT delorie DOT com

No.No. No . NO... Please refrain from doing that. There are DPMI functions
that can do the job for you.
Look at FAQ Section 15.2

----- Original Message -----
From: <Apester000 AT aol DOT com>
To: <djgpp AT delorie DOT com>
Sent: Friday, February 19, 1999 1:15 AM
Subject: Re: free RAM available


>>Hi,
>>
>>How can I get the free RAM available ?
>
>An easy (while not entirely accurate way) is just to make a little loop
>allocating memory until malloc failes.  i.e.:
>
>char *p;
>long l = 0;
>do
>{
>    p = malloc(1024);
>    if (p) l += 1024;
>} while (p);
>
>printf("Approximently % d megs of memory", l / 1024);
>
>Regards-
>Brandon Tallent
>

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019