Skip to content

Memory allocation test verifies incorrect variable #5318

Closed

Description

@GregDomjan
  • Which version of WiX are you building with?
    3.7/3.9.2/3.10.2
  • Describe the problem and the steps to reproduce it.

Reading code to identify an issue with a patch bundle using burn.
Noticed ExitOnNull testing same variable rgPatchInfo looks like it should be verifying rgPatchInfoToPackage on second usage.
https://github.com/wixtoolset/wix3/blob/wix3103/src/burn/engine/package.cpp#L255-256

        pPackages->rgPatchInfo = static_cast<MSIPATCHSEQUENCEINFOW*>(MemAlloc(sizeof(MSIPATCHSEQUENCEINFOW) * cMspPackages, TRUE));
        ExitOnNull(pPackages->rgPatchInfo, hr, E_OUTOFMEMORY, "Failed to allocate memory for MSP patch sequence information.");

        pPackages->rgPatchInfoToPackage = static_cast<BURN_PACKAGE**>(MemAlloc(sizeof(BURN_PACKAGE*) * cMspPackages, TRUE));
        ExitOnNull(pPackages->rgPatchInfo, hr, E_OUTOFMEMORY, "Failed to allocate memory for patch sequence information to package lookup.");

Activity

  1. added this to the v3.11 milestone on Jun 7, 2016
  2. assigned and unassigned on Jun 7, 2016
  3. assigned and unassigned on Jan 31, 2017
  4. robmen commented on Feb 12, 2017

    @robmen
    Member

    Fixed

  5. added theissue type on Nov 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions