diff options
| author | ptitSeb <sebastien.chev@gmail.com> | 2025-06-24 20:17:58 +0200 |
|---|---|---|
| committer | ptitSeb <sebastien.chev@gmail.com> | 2025-06-24 20:17:58 +0200 |
| commit | 09e39704ae85c84622e55ed0eb7efb6cd2214401 (patch) | |
| tree | 0162b19a5fcaef5926b2dd1d1dd30b46db9adfb1 /src | |
| parent | f14fa2f2ce44a6cbee3fcef58faf742bce992a66 (diff) | |
| download | box64-09e39704ae85c84622e55ed0eb7efb6cd2214401.tar.gz box64-09e39704ae85c84622e55ed0eb7efb6cd2214401.zip | |
[DYNAREC] Better check of limit for a dynablock
Diffstat (limited to 'src')
| -rw-r--r-- | src/dynarec/dynarec_native_pass.c | 2 | ||||
| -rw-r--r-- | src/tools/env.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/dynarec/dynarec_native_pass.c b/src/dynarec/dynarec_native_pass.c index f7d02f13..5fdcc11b 100644 --- a/src/dynarec/dynarec_native_pass.c +++ b/src/dynarec/dynarec_native_pass.c @@ -256,7 +256,7 @@ uintptr_t native_pass(dynarec_native_t* dyn, uintptr_t addr, int alternate, int } #else // check if block need to be stopped, because it's a 00 00 opcode (unreadeable is already checked earlier) - if((ok>0) && !dyn->forward && !(*(uint32_t*)addr)) { + if((ok>0) && !dyn->forward && (!(getProtection(addr)&PROT_READ) || !(*(uint32_t*)addr))) { if (dyn->need_dump) dynarec_log(LOG_NONE, "Stopping block at %p reason: %s\n", (void*)addr, "Next opcode is 00 00 00 00"); ok = 0; need_epilog = 1; diff --git a/src/tools/env.c b/src/tools/env.c index 3d3ad25b..4ce600c9 100644 --- a/src/tools/env.c +++ b/src/tools/env.c @@ -815,7 +815,7 @@ done: #else #error meh! #endif -#define DYNAREC_VERSION SET_VERSION(0, 0, 1) +#define DYNAREC_VERSION SET_VERSION(0, 0, 2) typedef struct DynaCacheHeader_s { char sign[10]; //"DynaCache\0" |