Changeset 10377 for trunk/src/kernel32/exceptions.cpp
- Timestamp:
- Jan 11, 2004, 12:57:53 PM (22 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kernel32/exceptions.cpp
r9910 r10377 1 /* $Id: exceptions.cpp,v 1.7 2 2003-03-06 10:22:26sandervl Exp $ */1 /* $Id: exceptions.cpp,v 1.73 2004-01-11 11:57:52 sandervl Exp $ */ 2 2 3 3 /* … … 1243 1243 map = Win32MemMapView::findMapByView(pERepRec->ExceptionInfo[1], &offset, accessflag); 1244 1244 if(map == NULL) { 1245 Win32MemMapNotify *map; 1246 1247 map = Win32MemMapNotify::findMapByView(pERepRec->ExceptionInfo[1], &offset, accessflag); 1248 if(!map) 1249 goto continueFail; 1250 1251 BOOL ret = map->notify(pERepRec->ExceptionInfo[1], offset, fWriteAccess); 1252 if(ret == TRUE) goto continueexecution; 1245 1253 goto continueFail; 1246 1254 } … … 1451 1459 } 1452 1460 //***************************************************************************** 1461 // Set exception handler if our handler has not yet been registered 1462 //***************************************************************************** 1463 void WIN32API ODIN_SetExceptionHandler(void *pExceptionRegRec) 1464 { 1465 BOOL fFound = FALSE; 1466 USHORT sel = RestoreOS2FS(); 1467 PEXCEPTIONREGISTRATIONRECORD pExceptRec = (PEXCEPTIONREGISTRATIONRECORD)QueryExceptionChain(); 1468 1469 while(pExceptRec != 0 && (ULONG)pExceptRec != -1) 1470 { 1471 if(pExceptRec->ExceptionHandler == OS2ExceptionHandler) 1472 { 1473 fFound = TRUE; 1474 break; 1475 } 1476 pExceptRec = pExceptRec->prev_structure; 1477 } 1478 if(!fFound) 1479 { 1480 OS2SetExceptionHandler(pExceptionRegRec); 1481 } 1482 SetFS(sel); 1483 } 1484 //***************************************************************************** 1485 // Remove exception handler if it was registered previously 1486 // 1487 //***************************************************************************** 1488 void WIN32API ODIN_UnsetExceptionHandler(void *pExceptionRegRec) 1489 { 1490 USHORT sel = RestoreOS2FS(); 1491 PEXCEPTIONREGISTRATIONRECORD pExceptRec = (PEXCEPTIONREGISTRATIONRECORD)QueryExceptionChain(); 1492 1493 if(pExceptRec == (PEXCEPTIONREGISTRATIONRECORD)pExceptionRegRec) { 1494 OS2UnsetExceptionHandler(pExceptionRegRec); 1495 } 1496 SetFS(sel); 1497 } 1498 //***************************************************************************** 1453 1499 //***************************************************************************** 1454 1500 #ifdef DEBUG
Note:
See TracChangeset
for help on using the changeset viewer.