Changeset 1860 for trunk/dll/wrappers.c
- Timestamp:
- Aug 22, 2015, 4:30:34 AM (10 years ago)
- File:
-
- 1 edited
-
trunk/dll/wrappers.c (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/dll/wrappers.c
r1848 r1860 6 6 Wrappers with error checking 7 7 8 Copyright (c) 2006, 20 08Steven H.Levine8 Copyright (c) 2006, 2015 Steven H.Levine 9 9 10 10 22 Jul 06 SHL Baseline … … 28 28 "#if 0" block for quick implementation should FM/2 start to use them. 29 29 Among these. xDosOpenL and xWinUpper still need work. The rest are ready for use. 30 20 Aug 15 SHL Add xDos...MutexSem and xDos..EventSem wrappers 30 31 31 32 ***********************************************************************/ … … 68 69 { 69 70 APIRET rc; 70 HFILE hFileLow = *phFile;71 HFILE hFileLow = *phFile; 71 72 72 73 rc = DosDupHandle(hFile, &hFileLow); … … 324 325 return apiret; 325 326 } 327 328 /** 329 * DosRequestMutexSem wrapper 330 */ 331 332 APIRET xDosRequestMutexSem(HMTX hmtx, ULONG ulTimeout) 333 { 334 APIRET apiret = DosRequestMutexSem(hmtx, ulTimeout); 335 336 if (apiret && (ulTimeout == SEM_INDEFINITE_WAIT || apiret != ERROR_TIMEOUT)) { 337 Dos_Error(MB_CANCEL, apiret, HWND_DESKTOP, pszSrcFile, __LINE__, 338 PCSZ_DOSREQUESTMUTEXSEM); 339 } 340 return apiret; 341 } 342 343 /** 344 * DosReleaseMutexSem wrapper 345 */ 346 347 APIRET xDosReleaseMutexSem(HMTX hmtx) 348 { 349 APIRET apiret = DosReleaseMutexSem(hmtx); 350 351 if (apiret) { 352 Dos_Error(MB_CANCEL, apiret, HWND_DESKTOP, pszSrcFile, __LINE__, 353 PCSZ_DOSRELEASEMUTEXSEM); 354 } 355 return apiret; 356 } 357 358 /** 359 * DosCreateEventSem wrapper 360 */ 361 362 APIRET xDosCreateEventSem (PSZ pszName,PHEV phev, ULONG flAttr, BOOL32 fState) 363 { 364 APIRET apiret = DosCreateEventSem (pszName,phev, flAttr, fState); 365 if (apiret) { 366 Dos_Error(MB_CANCEL, apiret, HWND_DESKTOP, pszSrcFile, __LINE__, 367 PCSZ_DOSCREATEEVENTSEM); 368 } 369 return apiret; 370 } 371 372 /** 373 * DosWaitEventSem wrapper 374 */ 375 376 APIRET xDosWaitEventSem(HEV hev, ULONG ulTimeout) 377 { 378 APIRET apiret = DosWaitEventSem(hev, ulTimeout); 379 380 if (apiret && (ulTimeout == SEM_INDEFINITE_WAIT || apiret != ERROR_TIMEOUT)) { 381 Dos_Error(MB_CANCEL, apiret, HWND_DESKTOP, pszSrcFile, __LINE__, 382 PCSZ_DOSWAITEVENTSEM); 383 } 384 return apiret; 385 } 386 387 /** 388 * DosPostEventSem wrapper 389 */ 390 391 APIRET xDosPostEventSem(HEV hev) 392 { 393 APIRET apiret = DosPostEventSem(hev); 394 395 if (apiret && apiret != ERROR_ALREADY_POSTED) { 396 Dos_Error(MB_CANCEL, apiret, HWND_DESKTOP, pszSrcFile, __LINE__, 397 PCSZ_DOSPOSTEVENTSEM); 398 } 399 return apiret; 400 } 401 402 /** 403 * DosResetEventSem wrapper 404 */ 405 406 APIRET xDosResetEventSem(HEV hev, PULONG pulPostCt) 407 { 408 APIRET apiret = DosResetEventSem(hev, pulPostCt); 409 410 if (apiret && apiret != ERROR_ALREADY_RESET) { 411 Dos_Error(MB_CANCEL, apiret, HWND_DESKTOP, pszSrcFile, __LINE__, 412 PCSZ_DOSRESETEVENTSEM); 413 } 414 return apiret; 415 } 416 417 /** 418 * DosFindFirst wrapper 419 */ 326 420 327 421 APIRET xDosFindFirst(PSZ pszFileSpec, … … 731 825 /* 732 826 * JBS: Wrappers for functions which... 733 * - are identified by klibc as "highmem-unsafe"734 * - not yet used by FM/2827 * - are identified by klibc as "highmem-unsafe" 828 * - not yet used by FM/2 735 829 */ 736 830
Note:
See TracChangeset
for help on using the changeset viewer.
