Changeset 617 for trunk/src/kernel32/exceptions.cpp
- Timestamp:
- Aug 22, 1999, 1:11:11 PM (26 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/kernel32/exceptions.cpp
r420 r617 1 /* $Id: exceptions.cpp,v 1. 9 1999-08-05 13:11:38 phallerExp $ */1 /* $Id: exceptions.cpp,v 1.10 1999-08-22 11:11:10 sandervl Exp $ */ 2 2 3 3 /* … … 55 55 #include <builtin.h> 56 56 #include "exceptions.h" 57 #include "except .h"57 #include "exceptutil.h" 58 58 #include "misc.h" 59 59 … … 450 450 excptaddr = getEBX(); 451 451 452 dprintf(("KERNEL32: KillWin32Process: Do you feel lucky, punk?!\n")); 453 // sprintf(excptmsg, "Fatal Exception %X at %X", excptnr, excptaddr); 454 // WinMessageBox(HWND_DESKTOP, NULL, excptmsg, "Win32 for OS/2", 0, MB_ERROR | MB_OK); 452 dprintf(("KERNEL32: KillWin32Process: Do you feel lucky, punk? (FS=%d)!\n", GetFS())); 453 //Restore original OS/2 TIB selector 454 RestoreOS2FS(); 455 455 456 SetExceptionChain((ULONG)0); 456 457 DosExit(EXIT_PROCESS, 666); … … 861 862 #endif 862 863 863 ERR _SystemOS2ExceptionHandler(PEXCEPTIONREPORTRECORD pERepRec,864 PEXCEPTIONREGISTRATIONRECORD pERegRec,865 PCONTEXTRECORD pCtxRec,866 PVOID p)864 ULONG APIENTRY OS2ExceptionHandler(PEXCEPTIONREPORTRECORD pERepRec, 865 PEXCEPTIONREGISTRATIONRECORD pERegRec, 866 PCONTEXTRECORD pCtxRec, 867 PVOID p) 867 868 { 868 869 // pERegRec->prev_structure = 0; … … 885 886 pCtxRec->ctx_stack[0].signexp = 0; 886 887 887 return ( ERR)(XCPT_CONTINUE_EXECUTION);888 return (XCPT_CONTINUE_EXECUTION); 888 889 889 890 case XCPT_PROCESS_TERMINATE: … … 911 912 pCtxRec->ctx_RegEax = pERepRec->ExceptionNum; 912 913 pCtxRec->ctx_RegEbx = pCtxRec->ctx_RegEip; 913 return ( ERR)(XCPT_CONTINUE_EXECUTION);914 return (XCPT_CONTINUE_EXECUTION); 914 915 915 916 default: //non-continuable exceptions … … 919 920 } 920 921 922 /***************************************************************************** 923 * Name : void OS2SetExceptionHandler 924 * Purpose : Sets the main thread exception handler in FS:[0] (original OS/2 FS selector) 925 * Parameters: exceptframe: pointer to exception handler frame on stack (2 ULONGs) 926 * Variables : 927 * Result : 928 * Remark : 929 * Status : 930 * 931 * Author : Sander van Leeuwen [Sun, 1999/08/21 12:16] 932 *****************************************************************************/ 933 void OS2SetExceptionHandler(void *exceptframe) 934 { 935 PEXCEPTIONREGISTRATIONRECORD pExceptRec = (PEXCEPTIONREGISTRATIONRECORD)exceptframe; 936 937 pExceptRec->prev_structure = 0; 938 pExceptRec->ExceptionHandler = OS2ExceptionHandler; 939 940 /* disable trap popups */ 941 // DosError(FERR_DISABLEEXCEPTION | FERR_DISABLEHARDERR); 942 943 DosSetExceptionHandler(pExceptRec); 944 } 945 946 /***************************************************************************** 947 * Name : void OS2UnsetExceptionHandler 948 * Purpose : Removes the main thread exception handler in FS:[0] (original OS/2 FS selector) 949 * Parameters: exceptframe: pointer to exception handler frame on stack (2 ULONGs) 950 * Variables : 951 * Result : 952 * Remark : 953 * Status : 954 * 955 * Author : Sander van Leeuwen [Sun, 1999/08/21 12:16] 956 *****************************************************************************/ 957 void OS2UnsetExceptionHandler(void *exceptframe) 958 { 959 DosUnsetExceptionHandler((PEXCEPTIONREGISTRATIONRECORD)exceptframe); 960 } 921 961 922 962 /*****************************************************************************
Note:
See TracChangeset
for help on using the changeset viewer.