locked
Application crashing when run as normal user RRS feed

  • Question

  • Hello,

    I am developing an application and need to run it in Windows 7 32 bit and it crashes the moment I run it as a normal user. However, it runs just fine when run as administrator.

    In the Windows 7 Event Viewer I get the following information:

    Faulting application name: ClientNT.exe, version: 1.30.0.780, time stamp: 0x4c052597
    Faulting module name: KERNELBASE.dll , version: 6.1.7600.16385, time stamp: 0x4a5bdaae
    Exception code: 0xe06d7363 Fault offset: 0x00009617
    Faulting process id: 0xedc
    Faulting application start time: 0x01cb01a1f7e77942
    Faulting application path: C:\ PrompterApp \Programs\ClientNT.exe
    Faulting module path: C:\Windows\system32\KERNELBASE.dll
    Report Id: 36018391-6d95-11df-8e27-001999672c6b

    I found there are three possible requested execution levels that can be used in the manifest file, asInvoker, highestAvailable and requireAdministrator (http://msdn.microsoft.com/en-us/library/bb756929.aspx). The level that I need to use is asInvoker so that normal users can run the application. However, the application won't run and the error that I mentioned earlier is displayed.

    In Windows XP, the application doesn't run when logged in as a normal user and no error is displayed.

    I tried to debug the application in Windows 7 and logged in as normal user using WinDBG and I get the following errors:

    *** ERROR: Symbol file could not be found.  Defaulted to export symbols for C:\Windows\system32\KERNELBASE.dll -
    KERNELBASE!RaiseException+0x54:
    75619617 c9              leave
    *** ERROR: Symbol file could not be found.  Defaulted to export symbols for C:\Windows\system32\msvcrt.dll -
    *** WARNING: Unable to verify checksum for C:\PrompterApp\Programs\StdLibU.dll
    *** ERROR: Symbol file could not be found.  Defaulted to export symbols for C:\PrompterApp\Programs\StdLibU.dll -

    Apparently the exception is thrown by the function RaiseException in KERNELBASE.dll.

    The call stack is:

    KERNELBASE!RaiseException+0x54
    msvcrt!CxxThrowException+0x45
    StdLibU!ThrowChainedException+0x7b
    ntdll!RtlQueryEnvironmentVariable_U+0x85
    ntdll!RtlGetVersion+0x1df
    ntdll!vsnwprintf+0x4e9
    ntdll!vsnwprintf+0x3eb
    ntdll!LdrInitializeThunk+0x10

    But it doesn't say how the execution gets in function LdrInitializeThunk inside the ntdll.dll

    Hope this information is enough.

    Thanks in advance,

    Polys

    Wednesday, June 9, 2010 2:26 PM

Answers

  • Hi Polys,

    Based on the above information, IMM32.DLL throws a first chance exception, but there is no any action to catch this exception. Therefore the application crashes when a second chance exception is thrown.

    We suggest you download and install a system debug symbol to debug a crash that occurs during a system call.

    Cheers,

    Yi


    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    • Marked as answer by Polys Tuesday, June 15, 2010 8:03 AM
    Friday, June 11, 2010 8:18 AM
  • Hi Yi,

    Thanks for your response. I finally managed to solve my problem using WinDbg. My application was trying to register a class that was creating a key in the registry. This was causing the application to crash when running it as a normal user, since normal users cannot modify the registry.

    Polys

    • Marked as answer by Yi Feng Li Tuesday, June 15, 2010 9:41 AM
    Tuesday, June 15, 2010 8:04 AM

All replies

  • Ok I am running the same application in Windows XP as a normal user and I get the following errors in WinDbg:

    Command:

    ModLoad: 76390000 763ad000   C:\WINDOWS\system32\IMM32.DLL

    (ce8.c50): C++ EH exception - code e06d7363 (first chance)

    (ce8.c50): C++ EH exception - code e06d7363 (first chance)

    (ce8.c50): C++ EH exception - code e06d7363 (!!! second chance !!!)

    eax=0012fc54 ebx=00000000 ecx=00000001 edx=ffffffff esi=e06d7363 edi=00000000

    eip=7c9666c6 esp=0012fc54 ebp=0012fca4 iopl=0         nv up ei pl zr na pe nc

    cs=001b  ss=0023  ds=0023  es=0023  fs=003b  gs=0000             efl=00000246

    ntdll!RtlRaiseStatus+0x26:
    7c9666c6 c9              leave

    Call Stack:
    ntdll!RtlRaiseStatus+0x26
    ntdll!_LdrpInitialize+0x241
    ntdll!KiUserApcDispatcher+0x7

    What does this mean? Does the application crash inside the RtlRaiseStatus method? And if yes, how can I interpret that hex address 0x26 to specify where exacltly in that method the application crashes?

     

    Thanks in advance,

    Polys
     

    Thursday, June 10, 2010 3:48 PM
  • Hi Polys,

    Based on the above information, IMM32.DLL throws a first chance exception, but there is no any action to catch this exception. Therefore the application crashes when a second chance exception is thrown.

    We suggest you download and install a system debug symbol to debug a crash that occurs during a system call.

    Cheers,

    Yi


    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    • Marked as answer by Polys Tuesday, June 15, 2010 8:03 AM
    Friday, June 11, 2010 8:18 AM
  • Hello,

    I am writing to check the status of the issue on your side.  Would you mind letting us know the result of the suggestions? 

    YI


    Please remember to mark the replies as answers if they help and unmark them if they provide no help.
    Welcome to the All-In-One Code Framework! If you have any feedback, please tell us.
    Tuesday, June 15, 2010 2:03 AM
  • Hi Yi,

    Thanks for your response. I finally managed to solve my problem using WinDbg. My application was trying to register a class that was creating a key in the registry. This was causing the application to crash when running it as a normal user, since normal users cannot modify the registry.

    Polys

    • Marked as answer by Yi Feng Li Tuesday, June 15, 2010 9:41 AM
    Tuesday, June 15, 2010 8:04 AM