Skip to content

fix: allow Open() on external files and add OpenDiskImage API#2

Open
borje wants to merge 2 commits into
GoToolSharing:mainfrom
borje:main
Open

fix: allow Open() on external files and add OpenDiskImage API#2
borje wants to merge 2 commits into
GoToolSharing:mainfrom
borje:main

Conversation

@borje
Copy link
Copy Markdown

@borje borje commented May 5, 2026

DirItem.Open() previously rejected DirItemExtFib (external files) with ErrIsDirectory. ExtFib uses the same block-vector layout as IntFib so the fix is to widen the guard to IsFile().

Also adds VBK.OpenDiskImage(path) which opens a .vmdk/.vhd/.vhdx entry and returns a flat readable DiskImage. Multi-extent VMDKs are reassembled automatically via the existing openVirtualDiskReader logic, with a raw-FibStream fallback for unrecognised disk formats.

Börje Granberg and others added 2 commits May 4, 2026 13:14
DirItem.Open() previously rejected DirItemExtFib (external files) with
ErrIsDirectory. ExtFib uses the same block-vector layout as IntFib so
the fix is to widen the guard to IsFile().

Also adds VBK.OpenDiskImage(path) which opens a .vmdk/.vhd/.vhdx entry
and returns a flat readable DiskImage. Multi-extent VMDKs are
reassembled automatically via the existing openVirtualDiskReader logic,
with a raw-FibStream fallback for unrecognised disk formats.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant