Changeset 7474 for trunk/src/kernel32/oslibdos.cpp
- Timestamp:
- Nov 29, 2001, 12:33:37 AM (24 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kernel32/oslibdos.cpp
r7398 r7474 1 /* $Id: oslibdos.cpp,v 1.8 5 2001-11-19 13:02:58phaller Exp $ */1 /* $Id: oslibdos.cpp,v 1.86 2001-11-28 23:33:37 phaller Exp $ */ 2 2 /* 3 3 * Wrappers for OS/2 Dos* API … … 178 178 case ERROR_WRITE_PROTECT: //19 179 179 return ERROR_WRITE_PROTECT_W; 180 181 case ERROR_BAD_UNIT: //20 182 return ERROR_BAD_UNIT_W; 180 183 181 184 case ERROR_NOT_READY: //21 … … 604 607 os2flags, 605 608 0L); /* No extended attribute */ 606 607 if(rc) { 608 if(rc == ERROR_TOO_MANY_OPEN_FILES) { 609 ULONG CurMaxFH; 610 LONG ReqCount = 32; 611 612 rc = DosSetRelMaxFH(&ReqCount, &CurMaxFH); 613 if(rc) { 614 dprintf(("DosSetRelMaxFH returned %d", rc)); 615 return 0; 616 } 617 dprintf(("DosOpen failed -> increased nr open files to %d", CurMaxFH)); 618 goto tryopen; 619 } 609 if(rc) 610 { 611 if(rc == ERROR_TOO_MANY_OPEN_FILES) 612 { 613 ULONG CurMaxFH; 614 LONG ReqCount = 32; 615 616 rc = DosSetRelMaxFH(&ReqCount, &CurMaxFH); 617 if(rc) 618 { 619 dprintf(("DosSetRelMaxFH returned %d", rc)); 620 620 return 0; 621 } 622 else return hFile; 621 } 622 dprintf(("DosOpen failed -> increased nr open files to %d", CurMaxFH)); 623 goto tryopen; 624 } 625 626 SetLastError(error2WinError(rc)); 627 return 0; 628 } 629 630 // OK, file was opened 631 SetLastError(ERROR_SUCCESS_W); 632 return hFile; 623 633 } 624 634 //******************************************************************************
Note:
See TracChangeset
for help on using the changeset viewer.