mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-10-09 19:36:45 +00:00
linux cgroup: also fix controllers()
This fix was found by Claude Code, but I manually reviewed this change and removed extraneous changes made by the AI tool. Co-authored-by: moderation <michael@sooper.org>
This commit is contained in:
@@ -185,9 +185,7 @@ pub fn controllers(alloc: Allocator, cgroup: []const u8) ![]const u8 {
|
||||
|
||||
// Read it all into memory -- we don't expect this file to ever
|
||||
// be that large.
|
||||
var reader_buf: [4096]u8 = undefined;
|
||||
var reader = file.reader(&reader_buf);
|
||||
const contents = try reader.interface.readAlloc(
|
||||
const contents = try file.readToEndAlloc(
|
||||
alloc,
|
||||
1 * 1024 * 1024, // 1MB
|
||||
);
|
||||
|
Reference in New Issue
Block a user