Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-16733

Exception with (EstablisherFrame & 7) != 0

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Untriaged
    • Priority: Major
    • Resolution: Unresolved
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      Exception happens when running dbghelp_apitest.exe pdb

      Running Wine Test, Module: dbghelp, Test: pdb
      

      It breaks on

              /* Check, if the resulting stack frame is valid */
              if ((EstablisherFrame < StackLow) ||
                  (EstablisherFrame > StackHigh) ||
                  (EstablisherFrame & 7))
              {
                  /// TODO: Handle DPC stack
                  __debugbreak(); // <= HERE
                  RtlRaiseStatus(STATUS_BAD_STACK);
              }
      

      Backtrace:

      kd> kp
       # Child-SP          RetAddr           Call Site
      00 00000000`0012e4f0 000007ff`b754de03 ntdll!RtplUnwindInternal(void * TargetFrame = 0x00000000`00000000, void * TargetIp = 0x00000000`00000000, struct _EXCEPTION_RECORD * ExceptionRecord = 0x00000000`0012efd0, void * ReturnValue = 0x00000000`00000000, struct _CONTEXT * ContextRecord = 0x00000000`0012eb00, struct _UNWIND_HISTORY_TABLE * HistoryTable = 0x00000000`00000000, unsigned long HandlerType = 1)+0x175 [E:\amd64\reactos\sdk\lib\rtl\amd64\unwind.c @ 749] 
      01 00000000`0012eab0 000007ff`b751854a ntdll!RtlDispatchException(struct _EXCEPTION_RECORD * ExceptionRecord = 0x00000000`0012efd0, struct _CONTEXT * ContextRecord = 0x00000000`0012eb00)+0x63 [E:\amd64\reactos\sdk\lib\rtl\amd64\except.c @ 129] 
      02 00000000`0012eb00 000007ff`b750ed1e ntdll!KiUserExceptionDispatcher+0x6
      03 00000000`0012f0a4 10000000`00000000 ntdll!LdrpCallInitRoutine(<function> * EntryPoint = 0xb754d6d1`00000000, void * BaseAddress = 0x10000000`000007ff, unsigned long Reason = 0, void * Context = 0x00000000`00000000)+0x2e [E:\amd64\reactos\dll\ntdll\ldr\ldrutils.c @ 107] 
      04 00000000`0012f0ac 00000001`00000000 0x10000000`00000000
      

      Which leads to

      BOOLEAN
      NTAPI
      LdrpCallInitRoutine(IN PDLL_INIT_ROUTINE EntryPoint,
                          IN PVOID BaseAddress,
                          IN ULONG Reason,
                          IN PVOID Context)
      {
          /* Call the entry */
          return EntryPoint(BaseAddress, Reason, Context);
      } <= HERE (on the ret)

      To do:

      • Why and where exactly does it except?
      • Why is the stack unaligned?

       

       

        Attachments

          Activity

            People

            • Assignee:
              ThePhysicist Timo Kreuzer
              Reporter:
              ThePhysicist Timo Kreuzer
            • Votes:
              1 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated: