From 3f3aaa01fa68a8ff4fc66a4ac8a808daf910e380 Mon Sep 17 00:00:00 2001 From: Michael Scire Date: Mon, 10 May 2021 07:50:39 -0700 Subject: [PATCH] git subrepo clone --force https://github.com/m4xw/emummc subrepo: subdir: "emummc" merged: "c6717b93" upstream: origin: "https://github.com/m4xw/emummc" branch: "develop" commit: "c6717b93" git-subrepo: version: "0.4.1" origin: "???" commit: "???" --- emummc/.gitrepo | 4 ++-- emummc/source/emuMMC/emummc.c | 14 +++++++------- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/emummc/.gitrepo b/emummc/.gitrepo index 2dbf99f6b..b0c176ad2 100644 --- a/emummc/.gitrepo +++ b/emummc/.gitrepo @@ -6,7 +6,7 @@ [subrepo] remote = https://github.com/m4xw/emuMMC branch = develop - commit = b355ee6a8f376faa615785419c7d73a8814d9d65 - parent = b24784f5c13a142bd0cb5d7edb82691c71f4bd00 + commit = c6717b9320247d3ec81b372adae5e5623be7d16b + parent = bf8de39e694dc64431180bc513ce110f07fc3531 method = rebase cmdver = 0.4.1 diff --git a/emummc/source/emuMMC/emummc.c b/emummc/source/emuMMC/emummc.c index 0447471ad..782b4837d 100644 --- a/emummc/source/emuMMC/emummc.c +++ b/emummc/source/emuMMC/emummc.c @@ -300,21 +300,21 @@ static uint64_t emummc_read_write_inner(void *buf, unsigned int sector, unsigned while (remaining > 0) { const unsigned int cur_sectors = MIN(remaining, f_emu.part_size - sector); - if (f_lseek(fp, sector << 9) != FR_OK) + if (f_lseek(fp, (u64)sector << 9) != FR_OK) return 0; // Out of bounds. if (is_write) { - if (f_write_fast(fp, buf, cur_sectors << 9) != FR_OK) + if (f_write_fast(fp, buf, (u64)cur_sectors << 9) != FR_OK) return 0; } else { - if (f_read_fast(fp, buf, cur_sectors << 9) != FR_OK) + if (f_read_fast(fp, buf, (u64)cur_sectors << 9) != FR_OK) return 0; } - buf = (char *)buf + (cur_sectors << 9); + buf = (char *)buf + ((u64)cur_sectors << 9); remaining -= cur_sectors; sector = 0; ++fp; @@ -336,14 +336,14 @@ static uint64_t emummc_read_write_inner(void *buf, unsigned int sector, unsigned break; } - if (f_lseek(fp, sector << 9) != FR_OK) + if (f_lseek(fp, (u64)sector << 9) != FR_OK) return 0; // Out of bounds. uint64_t res = 0; if (!is_write) - res = !f_read_fast(fp, buf, num_sectors << 9); + res = !f_read_fast(fp, buf, (u64)num_sectors << 9); else - res = !f_write_fast(fp, buf, num_sectors << 9); + res = !f_write_fast(fp, buf, (u64)num_sectors << 9); return res; }