Ignore:
Timestamp:
Oct 18, 2000, 7:09:34 PM (25 years ago)
Author:
sandervl
Message:

LoadLibraryExA + memory map close fix, added new registry keys for installation, don't log guard page violation

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kernel32/exceptions.cpp

    r4433 r4496  
    1 /* $Id: exceptions.cpp,v 1.46 2000-10-05 18:36:49 sandervl Exp $ */
     1/* $Id: exceptions.cpp,v 1.47 2000-10-18 17:09:31 sandervl Exp $ */
    22
    33/* WARNING: Compiling this module with ICC with optimizations turned on   */
     
    10481048#endif
    10491049
    1050 //in misc.cpp
    1051 void CheckLogException();
    1052 
    10531050ULONG APIENTRY OS2ExceptionHandler(PEXCEPTIONREPORTRECORD       pERepRec,
    10541051                                   PEXCEPTIONREGISTRATIONRECORD pERegRec,
     
    10581055  //SvL: Check if exception inside debug fprintf -> if so, clear lock so
    10591056  //     next dprintf won't wait forever
    1060   CheckLogException();
    1061 
     1057  LogException(ENTER_EXCEPTION);
    10621058
    10631059  /* Access violation at a known location */
     
    10831079                }
    10841080                dprintf(("KERNEL32: OS2ExceptionHandler: fix and continue\n"));
    1085                 return (XCPT_CONTINUE_EXECUTION);
     1081                goto continueexecution;
    10861082        }
    10871083        else
    10881084        {
    10891085                dprintf(("KERNEL32: OS2ExceptionHandler: continue search\n"));
    1090                 return (XCPT_CONTINUE_SEARCH);
     1086                goto continuesearch;
    10911087        }
    10921088
     
    10951091        dprintfException(pERepRec, pERegRec, pCtxRec, p);
    10961092        SetExceptionChain((ULONG)-1);
    1097         return (XCPT_CONTINUE_SEARCH);
     1093        goto continuesearch;
    10981094
    10991095  case XCPT_ACCESS_VIOLATION:
     
    11261122        }
    11271123        if(map->commitPage(offset, fWriteAccess) == TRUE)
    1128                 return (XCPT_CONTINUE_EXECUTION);
     1124                goto continueexecution;
    11291125
    11301126        //no break;
     
    11771173        //    recurse infinitely until we run out of stack space!!
    11781174        if (pERepRec->fHandlerFlags & EH_NESTED_CALL)
    1179                 return XCPT_CONTINUE_SEARCH;
     1175                goto continuesearch;
    11801176
    11811177#ifdef DEBUG
     
    11891185                if(OSLibDispatchException(pERepRec, pERegRec, pCtxRec, p) == TRUE)
    11901186                {
    1191                         return (XCPT_CONTINUE_EXECUTION);
     1187                        goto continueexecution;
    11921188                }
    11931189        }
    1194         else    return XCPT_CONTINUE_SEARCH; //pass on to OS/2 RTL or app exception handler
     1190        else    goto continuesearch; //pass on to OS/2 RTL or app exception handler
    11951191
    11961192        dprintf(("KERNEL32: OS2ExceptionHandler: Continue and kill\n"));
     
    11991195        pCtxRec->ctx_RegEax = pERepRec->ExceptionNum;
    12001196        pCtxRec->ctx_RegEbx = pCtxRec->ctx_RegEip;
    1201         return (XCPT_CONTINUE_EXECUTION);
     1197        goto continueexecution;
    12021198
    12031199  //@@@PH: growing thread stacks might need special treatment
    12041200  case XCPT_GUARD_PAGE_VIOLATION:
    1205     dprintf(("KERNEL32: OS2ExceptionHandler: trying to grow stack (continue search)"));
    1206     return (XCPT_CONTINUE_SEARCH);
     1201        //SvL: don't print anything here -> fatal hang if happens inside fprintf
     1202        //dprintf(("KERNEL32: OS2ExceptionHandler: trying to grow stack (continue search)"));
     1203        goto continuesearch;
    12071204
    12081205  case XCPT_SIGNAL:
    1209       if(pERepRec->ExceptionInfo[0] == XCPT_SIGNAL_KILLPROC)          /* resolve signal information */
    1210       {
    1211         SetExceptionChain((ULONG)-1);
    1212         return (XCPT_CONTINUE_SEARCH);
    1213       }
    1214       goto CrashAndBurn;
     1206        if(pERepRec->ExceptionInfo[0] == XCPT_SIGNAL_KILLPROC)          /* resolve signal information */
     1207        {
     1208            SetExceptionChain((ULONG)-1);
     1209            goto continuesearch;
     1210        }
     1211        goto CrashAndBurn;
    12151212
    12161213  default: //non-continuable exceptions
    12171214        dprintfException(pERepRec, pERegRec, pCtxRec, p);
    1218         return (XCPT_CONTINUE_SEARCH);
    1219   }
    1220   return (XCPT_CONTINUE_SEARCH);
     1215        goto continuesearch;
     1216  }
     1217continuesearch:
     1218  LogException(LEAVE_EXCEPTION);
     1219  return XCPT_CONTINUE_SEARCH;
     1220
     1221continueexecution:
     1222  LogException(LEAVE_EXCEPTION);
     1223  return XCPT_CONTINUE_EXECUTION;
    12211224}
    12221225
Note: See TracChangeset for help on using the changeset viewer.