1
0
mirror of synced 2026-02-03 23:42:50 +00:00

Add missing memory width assert preventing division by zero (#3546)

This commit is contained in:
Emil J
2022-11-09 10:34:25 +01:00
committed by GitHub
parent faa1c2e7fe
commit c75f12a989

View File

@@ -504,6 +504,7 @@ void Mem::check() {
int mask = (1 << max_wide_log2) - 1;
log_assert(!(start_offset & mask));
log_assert(!(size & mask));
log_assert(width != 0);
}
namespace {