Work on extraction
Created DataExtractor & DataReader Created Lookup tables
This commit is contained in:
+3
-1
@@ -8,7 +8,7 @@ const Directory = @This();
|
||||
|
||||
entries: []Entry,
|
||||
|
||||
pub fn init(alloc: std.mem.Allocator, rdr: *Reader, size: u32) !Directory {
|
||||
pub fn init(alloc: std.mem.Allocator, rdr: *Reader, size: u32) Error!Directory {
|
||||
if (size <= 3) return .{ .entries = &[0]Entry{} };
|
||||
|
||||
var entries: std.ArrayList(Entry) = try .initCapacity(alloc, 50);
|
||||
@@ -56,6 +56,8 @@ pub fn deinit(self: Directory, alloc: std.mem.Allocator) void {
|
||||
|
||||
// Types
|
||||
|
||||
pub const Error = Reader.Error || std.mem.Allocator.Error;
|
||||
|
||||
pub const Entry = struct {
|
||||
inode_num: u32,
|
||||
block_start: u32,
|
||||
|
||||
Reference in New Issue
Block a user