X-Originating-IP: [200.42.6.246] From: "Norberto Alfredo Bensa" To: "DJGPP" References: Subject: Re: getdfree on FAT32? Date: Mon, 25 Dec 2000 18:17:00 -0300 Organization: nBens@ Computers MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 Message-ID: X-OriginalArrivalTime: 25 Dec 2000 21:33:56.0799 (UTC) FILETIME=[62DCE4F0:01C06EBA] Reply-To: djgpp AT delorie DOT com From: "Eli Zaretskii" > > On Sun, 24 Dec 2000, Norberto Alfredo Bensa wrote: > > > I was suspecting of that "rescaling" free clusters stuff from the beggining, > > but I was afraid to ask (I guess I must trust more on my instincts) > > What rescaling? /* We trust previous int21 call more if free hasn't maxed out. */ if( free < blocks ) { /* Previous bsize is a multiple of this bsize, so the multiplication and division here is really a rescaling of the previous free value. */ free *= bsize; bsize = _farpeekw (_dos_ds, __tb + 0x2 + 0x2) * ( _farpeekb (_dos_ds, __tb + 0x2 + 0x4) + 1 ); free /= bsize; } else { free = _farpeekw (_dos_ds, __tb + 0x2 + 0x1f) + 65536 * _farpeekw (_dos_ds, __tb + 0x2 + 0x21); bsize = _farpeekw (_dos_ds, __tb + 0x2 + 0x2) * ( _farpeekb (_dos_ds, __tb + 0x2 + 0x4) + 1 ); } > > > PS: Please forgive me for attaching files but I don't know where to send > > them... > > This is explained in the FAQ (section 22.3). > Thanks, I'm sending a diff to DJ right now, just let me change the layout of the sources back to its original form (tabs, spaces, indent, etc.) Regards, Norberto