From: notaz Date: Tue, 19 Dec 2023 19:06:18 +0000 (+0200) Subject: drc: try to unbreak 3ds X-Git-Tag: r24l~13 X-Git-Url: https://notaz.gp2x.de/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dcbfae8a2877618ef40cb5aea6f1a7027ae40331;p=pcsx_rearmed.git drc: try to unbreak 3ds it doesn't implement _SC_PAGESIZE --- diff --git a/libpcsxcore/new_dynarec/new_dynarec.c b/libpcsxcore/new_dynarec/new_dynarec.c index b4295239..d9438d88 100644 --- a/libpcsxcore/new_dynarec/new_dynarec.c +++ b/libpcsxcore/new_dynarec/new_dynarec.c @@ -6263,11 +6263,13 @@ void new_dynarec_clear_full(void) static int pgsize(void) { + long ret = -1; #ifdef _SC_PAGESIZE - return sysconf(_SC_PAGESIZE); -#else - return 4096; + ret = sysconf(_SC_PAGESIZE); #endif + if (ret < 1) + ret = 4096; + return ret; } void new_dynarec_init(void)