Date: Mon, 13 Sep 1999 13:08:02 +0200 (IST) From: Eli Zaretskii X-Sender: eliz AT is To: Niko Salminen cc: djgpp AT delorie DOT com Subject: Re: Allocating dos memory fails In-Reply-To: <37D80427.CA61678F@draconus.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: djgpp AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk On Thu, 9 Sep 1999, Niko Salminen wrote: > I have a problem with my MSCDEX routines: Most of my > _go32_dpmi_allocate_dos_memory() calls work just fine, but in one > function, it returns me a non-zero (an error) and allocates nothing. How much memory, overall, did you allocate? Is it possible that you have used up all the conventional memory? > _go32_dpmi_seginfo myinfo; > info.size=1; > _go32_dpmi_allocate_dos_memory(&info); > > In all functions but the troublesome one this works just fine. What, if any, are the differences between the code in functions that work and in the one that doesn't? Do you ask for the same size, for example? It is also possible that, due to some unrelated bug, your code overwrites the _go32_dpmi_seginfo structure, so the function gets it garbled.