From: Toni Wilen Date: Wed, 7 Aug 2019 18:16:10 +0000 (+0300) Subject: Cleanups. X-Git-Tag: 4300~169 X-Git-Url: https://git.unchartedbackwaters.co.uk/w/?a=commitdiff_plain;h=5ebb130e98ffacbbe13fc01a15cd1e125ee53476;p=francis%2Fwinuae.git Cleanups. --- diff --git a/cfgfile.cpp b/cfgfile.cpp index 810045ff..e2d5ac9d 100644 --- a/cfgfile.cpp +++ b/cfgfile.cpp @@ -1531,7 +1531,7 @@ static bool cfgfile_readromboard(const TCHAR *option, const TCHAR *value, struct _tcscpy(tmp1, _T("romboard_options")); if (!_tcsicmp(option, tmp1)) { TCHAR *endptr; - TCHAR *s, *s1, *s2; + TCHAR *s1, *s2; s1 = cfgfile_option_get(value, _T("start")); s2 = cfgfile_option_get(value, _T("end")); rb->size = 0; diff --git a/drawing.cpp b/drawing.cpp index ebb76f71..39307e4b 100644 --- a/drawing.cpp +++ b/drawing.cpp @@ -256,9 +256,6 @@ static int last_redraw_point; #define MAX_STOP 30000 static int first_drawn_line, last_drawn_line; -static int first_block_line, last_block_line; - -#define NO_BLOCK -3 /* These are generated by the drawing code from the line_decisions array for each line that needs to be drawn. These are basically extracted out of @@ -1063,10 +1060,10 @@ static void pfield_init_linetoscr (bool border) pixels_offset = MAX_PIXELS_PER_LINE - ddf_left; leftborderhidden = playfield_start - native_ddf_left2; -#if 0 + if (hblank_left_start > playfield_start) leftborderhidden += hblank_left_start - playfield_start; -#endif + src_pixel = MAX_PIXELS_PER_LINE + res_shift_from_window(leftborderhidden); if (may_require_hard_way) { @@ -3642,7 +3639,6 @@ static void init_drawing_frame (void) last_drawn_line = 0; first_drawn_line = 32767; - first_block_line = last_block_line = NO_BLOCK; if (ad->frame_redraw_necessary) { reset_decision_table(); ad->custom_frame_redraw_necessary = 1; diff --git a/od-win32/mman.cpp b/od-win32/mman.cpp index edb11199..82277f9e 100644 --- a/od-win32/mman.cpp +++ b/od-win32/mman.cpp @@ -192,11 +192,11 @@ bool preinit_shm (void) max_allowed_mman = 256; } } else if (maxmem > 0) { - size64 = maxmem * 1024 * 1024; + size64 = (uae_u64)maxmem * 1024 * 1024; } if (size64 < 8 * 1024 * 1024) size64 = 8 * 1024 * 1024; - if (max_allowed_mman * 1024 * 1024 > size64) + if ((uae_u64)max_allowed_mman * 1024 * 1024 > size64) max_allowed_mman = size64 / (1024 * 1024); uae_u32 natmem_size = (max_allowed_mman + 1) * 1024 * 1024;