Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Crash during installation during LogId #4739

Closed
wixbot opened this issue Apr 15, 2015 · 7 comments
Closed

Crash during installation during LogId #4739

wixbot opened this issue Apr 15, 2015 · 7 comments
Milestone

Comments

@wixbot
Copy link

wixbot commented Apr 15, 2015

We have several cases (at least 4) where the WiX code crashed during installation, at different moments. We can't reproduce consistently. The crash appears to be random, and occurred on different computers. We had the crashes with both WiX 3.9 and WiX 3.9 R2.

We had several different callstacks, but all of them had the following functions at the top: LogId, LogIdModuleArgs, LogIdWork, _FormatMessageW

One of the callstack is:

KernelBase.dll!_BaseDllFormatMessage@32�()  Unknown
KernelBase.dll!_FormatMessageW@28�()    Unknown
ABC_Setup.exe!LogIdWork(REPORT_LEVEL rl, HINSTANCE__ * hModule, unsigned long dwLogId, char * args, int fLOGUTIL_NEWLINE) Line 825  C++
ABC_Setup.exe!LogIdModuleArgs(REPORT_LEVEL rl, unsigned long dwLogId, HINSTANCE__ * hModule, char * args) Line 550  C++
ABC_Setup.exe!LogId(REPORT_LEVEL rl, unsigned long dwLogId, ...) Line 147   C++
ABC_Setup.exe!DependencyPlanPackageBegin(int fPerMachine, _BURN_PACKAGE * pPackage, _BURN_PLAN * pPlan) Line 348    C++
ABC_Setup.exe!ProcessPackage(int fBundlePerMachine, int fPlanCompatible, _BURN_USER_EXPERIENCE * pUX, _BURN_PLAN * pPlan, _BURN_PACKAGE * pPackage, _BURN_LOGGING * pLog, _BURN_VARIABLES * pVariables, BOOTSTRAPPER_DISPLAY display, BOOTSTRAPPER_RELATION_TYPE relationType, const wchar_t * wzLayoutDirectory, void * * phSyncpointEvent, _BURN_ROLLBACK_BOUNDARY * * ppRollbackBoundary, PLAN_NONPERMANENT_PACKAGE_INDICES * pNonpermanentPackageIndices) Line 884  C++
ABC_Setup.exe!PlanPackages(_BURN_REGISTRATION * pRegistration, _BURN_USER_EXPERIENCE * pUX, _BURN_PACKAGES * pPackages, _BURN_PLAN * pPlan, _BURN_LOGGING * pLog, _BURN_VARIABLES * pVariables, int fBundleInstalled, BOOTSTRAPPER_DISPLAY display, BOOTSTRAPPER_RELATION_TYPE relationType, const wchar_t * wzLayoutDirectory, void * * phSyncpointEvent) Line 471 C++
ABC_Setup.exe!CorePlan(_BURN_ENGINE_STATE * pEngineState, BOOTSTRAPPER_ACTION action) Line 456  C++
ABC_Setup.exe!ProcessMessage(_BURN_ENGINE_STATE * pEngineState, const tagMSG * pmsg) Line 644   C++
ABC_Setup.exe!RunApplication(_BURN_ENGINE_STATE * pEngineState, int * pfReloadApp) Line 598 C++
ABC_Setup.exe!RunNormal(HINSTANCE__ * hInstance, _BURN_ENGINE_STATE * pEngineState) Line 405    C++
ABC_Setup.exe!EngineRun(HINSTANCE__ * hInstance, const wchar_t * wzCommandLine, int nCmdShow, unsigned long * pdwExitCode) Line 144 C++
ABC_Setup.exe!wWinMain(HINSTANCE__ * hInstance, HINSTANCE__ * __formal, wchar_t * lpCmdLine, int nCmdShow) Line 30  C++

Another callstack had the following call to LogId, which also crashed at the last LogId crash:

static HRESULT ExecutePackageComplete(
    __in BURN_USER_EXPERIENCE* pUX,
    __in BURN_VARIABLES* pVariables,
    __in BURN_PACKAGE* pPackage,
    __in HRESULT hrOverall,
    __in HRESULT hrExecute,
    __in BOOL fRollback,
    __out BOOTSTRAPPER_APPLY_RESTART* pRestart,
    __out BOOL* pfRetry,
    __out BOOL* pfSuspend
    )
{
    HRESULT hr = FAILED(hrOverall) ? hrOverall : hrExecute; // if the overall function failed use that otherwise use the execution result.

    // send package execute complete to UX
    int nResult = pUX->pUserExperience->OnExecutePackageComplete(pPackage->sczId, hr, *pRestart, FAILED(hrOverall) || SUCCEEDED(hrExecute) || pPackage->fVital ? IDNOACTION : IDIGNORE);
    if (IDRESTART == nResult)
    {
        *pRestart = BOOTSTRAPPER_APPLY_RESTART_INITIATED;
    }
    *pfRetry = (FAILED(hrExecute) && IDRETRY == nResult); // allow retry only on failures.
    *pfSuspend = (IDSUSPEND == nResult);

    // Remember this package as the package that initiated the forced restart.
    if (BOOTSTRAPPER_APPLY_RESTART_INITIATED == *pRestart)
    {
        // Best effort to set the forced restart package variable.
        VariableSetString(pVariables, BURN_BUNDLE_FORCED_RESTART_PACKAGE, pPackage->sczId, TRUE);
    }

    // If we're retrying, leave a message in the log file and say everything is okay.
    if (*pfRetry)
    {
        LogId(REPORT_STANDARD, MSG_APPLY_RETRYING_PACKAGE, pPackage->sczId, hrExecute);
        hr = S_OK;
    }
    else if (SUCCEEDED(hrOverall) && FAILED(hrExecute) && IDIGNORE == nResult && !pPackage->fVital) // If we *only* failed to execute and the BA ignored this *not-vital* package, say everything is okay.
    {
        LogId(REPORT_STANDARD, MSG_APPLY_CONTINUING_NONVITAL_PACKAGE, pPackage->sczId, hrExecute);
        hr = S_OK;
    }
    else
    {
>        LogId(REPORT_STANDARD, MSG_APPLY_COMPLETED_PACKAGE, LoggingRollbackOrExecute(fRollback), pPackage->sczId, hr, LoggingRestartToString(*pRestart));
    }

    return hr;
}

The actual error is:

Unhandled exception at 0x7723915C (KernelBase.dll) in ABC_Setup.exe: 0xC0000006: In page error reading location 0x0035BCEE (status code 0xC00000C4).

Originally opened by decasteljau

@wixbot
Copy link
Author

wixbot commented Apr 21, 2015

Can you try to reproduce using PageHelp? Seems like it's a memory corruption that PageHeap's good at sniffing them out.

https://msdn.microsoft.com/en-us/library/windows/hardware/ff549561%28v=vs.85%29.aspx

Release changed from v3.9 to v3.x

@wixbot
Copy link
Author

wixbot commented Apr 21, 2015

Can you try to reproduce using PageHelp? Seems like it's a memory corruption that PageHeap's good at sniffing them out.

https://msdn.microsoft.com/en-us/library/windows/hardware/ff549561%28v=vs.85%29.aspx

@wixbot
Copy link
Author

wixbot commented May 24, 2015

Did page heap expose anything? Are you using WixStdBA or a custom one?

Originally posted by rseanhall
Status changed from Open to Untriaged

@wixbot
Copy link
Author

wixbot commented Jun 9, 2015

We need more detail to act on this bug. If you can provide this, please re-open the bug.

Resolution set to moreinfo
Status changed from Untriaged to Resolved

@wixbot
Copy link
Author

wixbot commented Jun 9, 2015

We need more detail to act on this bug. If you can provide this, please re-open the bug.

2 similar comments
@wixbot
Copy link
Author

wixbot commented Jun 9, 2015

We need more detail to act on this bug. If you can provide this, please re-open the bug.

@wixbot
Copy link
Author

wixbot commented Jun 9, 2015

We need more detail to act on this bug. If you can provide this, please re-open the bug.

@wixbot wixbot added this to the v3.x milestone Dec 20, 2015
@wixbot wixbot closed this as completed Dec 20, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant