From c5711b4689e7c0b8095f7a46b90115a3fb0955c9 Mon Sep 17 00:00:00 2001 From: Ulrich Weigand Date: Sat, 10 Jul 1999 11:45:12 +0000 Subject: [PATCH] Bugfix: correctly cope with end > 0xfffe. --- memory/local.c | 1 + 1 file changed, 1 insertion(+) diff --git a/memory/local.c b/memory/local.c index eed1a4b801..607e7b6392 100644 --- a/memory/local.c +++ b/memory/local.c @@ -355,6 +355,7 @@ BOOL16 WINAPI LocalInit16( HANDLE16 selector, WORD start, WORD end ) DWORD size = GlobalSize16( GlobalHandle16( selector ) ); start = (WORD)(size > 0xffff ? 0xffff : size) - 1; + if ( end > 0xfffe ) end = 0xfffe; start -= end; end += start;