Skip to content

[Q] Is it true that StringHeap must always be present in a portable PDB metadata? #665

@ivanpovazan

Description

@ivanpovazan

In the following section of the code, StringHeap is treated as it will always be present in the metadata, while for Guid and Blob heaps that is not the case:

https://github.com/jbevain/cecil/blob/f74703c36e9a7626ef435399c45d27a84b246864/Mono.Cecil.PE/ImageReader.cs#L480#L486

I am working on a tool for creating portable PDB metadata (and verifying it with Cecil library), and in some cases when StringHeap is not present in the portable PDB metadata, Cecil library throws null exception at:

int stridx_size = image.StringHeap.IndexSize;

Does StringHeap have to be present in portable PDB metadata in all cases?
And if so, is this requirement documented anywhere?

Thank you

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions