Use usize instead of u64 in most places for better 32-bit compatibility

Signed-off-by: AnErrupTion <anerruption@disroot.org>
This commit is contained in:
AnErrupTion
2024-07-29 13:46:14 +02:00
parent ee488ba36e
commit c1f1c8f5c1
10 changed files with 50 additions and 50 deletions

View File

@@ -20,9 +20,9 @@ pub fn tryMigrateSaveFile(user_buf: *[32]u8, path: []const u8) Save {
reader.streamUntilDelimiter(session_fbs.writer(), '\n', 20) catch {};
const session_index_str = session_fbs.getWritten();
var session_index: ?u64 = null;
var session_index: ?usize = null;
if (session_index_str.len > 0) {
session_index = std.fmt.parseUnsigned(u64, session_index_str, 10) catch return save;
session_index = std.fmt.parseUnsigned(usize, session_index_str, 10) catch return save;
}
save.session_index = session_index;