Table of Contents

Class AddressFixupExtensions

Namespace
AsmResolver.PE.Code
Assembly
AsmResolver.PE.dll

Provides extensions to PatchedSegment that adds patch overloads to quickly construct instances of AddressFixupPatch.

public static class AddressFixupExtensions
Inheritance
AddressFixupExtensions
Inherited Members

Methods

Patch(PatchedSegment, in AddressFixup)

Adds an address fixup to the list of patches to apply.

public static PatchedSegment Patch(this PatchedSegment segment, in AddressFixup fixup)

Parameters

segment PatchedSegment

The segment to add the patch to.

fixup AddressFixup

The fixup to apply.

Returns

PatchedSegment

The patched segment.

Patch(PatchedSegment, uint, AddressFixupType, ISymbol)

Adds an address fixup to the list of patches to apply.

public static PatchedSegment Patch(this PatchedSegment segment, uint relativeOffset, AddressFixupType type, ISymbol referencedObject)

Parameters

segment PatchedSegment

The segment to add the patch to.

relativeOffset uint

The offset to start writing the address at, relative to the start of the segment.

type AddressFixupType

The type of address to write.

referencedObject ISymbol

The reference to write the RVA for.

Returns

PatchedSegment

The patched segment.

Patch(PatchedSegment, uint, AddressFixupType, uint)

Adds an address fixup to the list of patches to apply.

public static PatchedSegment Patch(this PatchedSegment segment, uint relativeOffset, AddressFixupType type, uint symbolOffset)

Parameters

segment PatchedSegment

The segment to add the patch to.

relativeOffset uint

The offset to start writing the address at, relative to the start of the segment.

type AddressFixupType

The type of address to write.

symbolOffset uint

The offset within the segment to point to, relative to the start of the segment.

Returns

PatchedSegment

The patched segment.