X-Authentication-Warning: delorie.com: mail set sender to djgpp-bounces using -f X-Recipient: djgpp AT delorie DOT com Date: Tue, 24 Mar 2009 18:23:37 -0400 From: Ethan Rosenberg Subject: Re: DJGPP Setup? In-reply-to: To: djgpp AT delorie DOT com Message-id: <0KH100CJT7JOE5E0@mta4.srv.hcvlny.cv.net> MIME-version: 1.0 X-Mailer: QUALCOMM Windows Eudora Version 7.1.0.9 Content-type: text/plain; charset=us-ascii; format=flowed Content-transfer-encoding: 7BIT References: <0KGZ00GQ8UBIYMM0 AT mta4 DOT srv DOT hcvlny DOT cv DOT net> <0KH0008ZTYD2KCK1 AT mta2 DOT srv DOT hcvlny DOT cv DOT net> Reply-To: djgpp AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: djgpp AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk At 05:40 PM 3/24/2009, you wrote: > > Date: Tue, 24 Mar 2009 15:05:15 -0400 > > From: Ethan Rosenberg > > > > 1] The program correctly opens all the files and runs. It fails > > after about 20 writes to the files in the code that I sent you. > >It could fail because of reasons unrelated to the number of files >you open. > > > 2] RE: The code that you sent me... which header files do I need? > >I didn't send any code that you should compile. ++++++++++ This is the code to which I refer - /* See if we need to expand the tables. Check this BEFORE it might fail, so that when we hit the count'th request, we've already up'd it. */ if ((size_t)fd >= (count-1) && count < 255) { int oldcount = count; count = 255; __file_handle_modes = (char *)malloc(count * sizeof(*__file_handle_modes)); memcpy(__file_handle_modes, init_file_handle_modes, sizeof(init_file_handle_modes)); memset(__file_handle_modes + oldcount, 0, (count-oldcount)*sizeof(__file_handle_modes[0])); /* Tell DOS to allow more */ r.h.ah = 0x67; r.x.bx = count; __dpmi_int(0x21, &r); } Did you or Rod Pemberton send me the above code? Ethan