Skip to content

Commit

Permalink
version_hint should be first element of unpacked struct
Browse files Browse the repository at this point in the history
  • Loading branch information
bmaranville committed Aug 29, 2024
1 parent f228420 commit b39d1bd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion esm/misc-low-level.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ import { _structure_size, _padded_size, _unpack_struct_from, struct, assert, _un

export class SuperBlock {
constructor(fh, offset) {
let version_hint = struct.unpack_from('<B', fh, offset + 8);
let version_hint = struct.unpack_from('<B', fh, offset + 8)[0];
var contents;
if (version_hint == 0) {
contents = _unpack_struct_from(SUPERBLOCK_V0, fh, offset);
Expand Down

0 comments on commit b39d1bd

Please sign in to comment.