puae 2.3.0

parent 2d238d19
...@@ -2062,8 +2062,9 @@ uae_u8 *mapped_malloc (size_t s, const TCHAR *file) ...@@ -2062,8 +2062,9 @@ uae_u8 *mapped_malloc (size_t s, const TCHAR *file)
int id; int id;
void *answer; void *answer;
shmpiece *x; shmpiece *x;
static int recurse;
if (!canjit()) { if (!canjit ()) {
nocanbang (); nocanbang ();
return xcalloc (uae_u8, s + 4); return xcalloc (uae_u8, s + 4);
} }
...@@ -2097,8 +2098,13 @@ uae_u8 *mapped_malloc (size_t s, const TCHAR *file) ...@@ -2097,8 +2098,13 @@ uae_u8 *mapped_malloc (size_t s, const TCHAR *file)
shm_start = x; shm_start = x;
return (uae_u8*)answer; return (uae_u8*)answer;
} }
if (recurse)
return NULL;
nocanbang (); nocanbang ();
return mapped_malloc (s, file); recurse++;
uae_u8 *r = mapped_malloc (s, file);
recurse--;
return r;
} }
#endif #endif
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment