diff --git a/src/olympic/keel/src/media.cpp b/src/olympic/keel/src/media.cpp index 01e6f90d..c6982d21 100644 --- a/src/olympic/keel/src/media.cpp +++ b/src/olympic/keel/src/media.cpp @@ -53,10 +53,12 @@ static ox::Error buildUuidMap(Context &ctx, ox::StringViewCR path) noexcept { OX_REQUIRE_M(filePath, ox::join("/", ox::Array<ox::StringView, 2>{path, f})); OX_REQUIRE(stat, ctx.rom->stat(filePath)); if (stat.fileType == ox::FileType::NormalFile) { - OX_REQUIRE(data, ctx.rom->read(filePath)); - auto const [hdr, err] = readAssetHeader(data); + ox::Array<char, K1HdrSz> buff; + OX_RETURN_ERROR( + ctx.rom->read(filePath, 0, buff.size(), buff)); + auto const [uuid, err] = readUuidHeader(buff); if (!err) { - createUuidMapping(ctx, filePath, hdr.uuid); + createUuidMapping(ctx, filePath, uuid); } } else if (stat.fileType == ox::FileType::Directory) { if (!beginsWith(f, ".")) {