custom: add Write.deinit and fix WildNoise.deinit
This commit is contained in:
parent
e142285a32
commit
a33db9f060
1 changed files with 3 additions and 1 deletions
|
@ -91,7 +91,7 @@ pub const WildNoise = struct {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
pub fn deinit(self: *RandomNoise) void {
|
pub fn deinit(self: *WildNoise) void {
|
||||||
if (self.allocator == null) return;
|
if (self.allocator == null) return;
|
||||||
if (self.rand_buf == null) return;
|
if (self.rand_buf == null) return;
|
||||||
self.allocator.?.free(self.rand_buf.?);
|
self.allocator.?.free(self.rand_buf.?);
|
||||||
|
@ -125,6 +125,8 @@ pub const Write = struct {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn deinit(self: *Write) void {}
|
||||||
|
|
||||||
pub fn run(self: *Write, bufs: *RunBuffers) void {
|
pub fn run(self: *Write, bufs: *RunBuffers) void {
|
||||||
bufs.out[0] = self.data;
|
bufs.out[0] = self.data;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue