Skip to content
PdbFileResolveRva

PdbFileResolveRva

Description

Locate the function whose [rva, rva + size) range contains rva. (For the trailing function whose size is 0 we accept any rva >= function.rva.)

Success

Returns a pointer to the matching entry. Valid until PdbFileDeinit.

Failure

Returns NULL.

Usage example (Cross-references)

Usage examples (Cross-references)
        // Direct lookup by RVA.
        if (ok) {
            const PdbFunction *f = PdbFileResolveRva(&pdb, 0x1100);
            ok                   = f && ZstrCompare(f->name, "my_function") == 0;
        }
        u32 rva = (u32)rva64;
    
        const PdbFunction *f = PdbFileResolveRva(&entry->pdb, rva);
        if (!f)
            return false;
    }
    
    const PdbFunction *PdbFileResolveRva(const PdbFile *self, u32 rva) {
        if (!self || self->functions.length == 0)
            return NULL;
Last updated on