🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.os.os2
Article #200

Re: Using >20 files in OS/2

#200
From: Joseph D. Shapiro
Date: Tue, 21 Nov 1989 18:34
27 lines
1485 bytes
In article <14570001@otter.hpl.hp.com> hjb@otter.hpl.hp.com (Harry Barman) writes:
>We are porting a Unix program to OS/2 1.1.  We started off using the C library,
>but hit up against the 20 file limit.  I can't find anything in the
>documentation that says how to increase it, is such a thing possible???
>
>For many of the files,  we can use DosOpen, and DosSetMaxFH to allocate more
>file handles.   But... we still want to use fscanf and friends for some of the
>files.  The trouble is that the Dos file calls don't seem to coexist with the
.
.
.


There is an
	extern int near _nfiles;

which you can set to the new value specified through DosSetMaxFH.

Another solution is to modify to startup file CRT0DAT.ASM, uncommenting
a few lines which are there just to do the DosSetMaxFH and set _nfiles.
It uses a defile called NFILE, which you may have to modify in stdio.h.

-- 
__--__--__--__--__--__--__--__--__--__--__--__--__--__--__--__--__--__--__--__
Joe Shapiro					"My other car is a turbo...
ISC-Bunker Ramo     				 ...too."
{decvax,yale,philabs,oliveb}!bunker!shap
Technical Details
Message-ID: <8590@bunker.UUCP>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!yale!bunker!shap
References: <14570001@otter.hpl.hp.com>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!yale!bunker!shap
From: shap@bunker.UUCP (Joseph D. Shapiro)
Newsgroups: comp.os.os2
Subject: Re: Using >20 files in OS/2
Message-ID: <8590@bunker.UUCP>
Date: 21 Nov 89 18:34:32 GMT
References: <14570001@otter.hpl.hp.com>
Reply-To: shap@clunker.UUCP (Joseph D. Shapiro)
Organization: ISC-Bunker Ramo, an Olivetti Company, Shelton, Ct
Lines: 27