From 31a9b25465c6ac6568a77d274ffeb0f5d1370668 Mon Sep 17 00:00:00 2001 From: OBattler Date: Sat, 3 Jun 2017 02:11:36 +0200 Subject: [PATCH] The sbTips array is now set to all 0's on initialization so that the functions to create tips no longer mistakenly think the pointers are non-null due to unpredictable data, should get rid of the start/setting changes crashes. --- src/WIN/win.c | 1 + src/pci.c | 4 ++-- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/WIN/win.c b/src/WIN/win.c index fe7e8fcd9..c7dbdabe7 100644 --- a/src/WIN/win.c +++ b/src/WIN/win.c @@ -1088,6 +1088,7 @@ void update_status_bar_panes(HWND hwnds) memset(sb_part_icons, 0, sb_parts * sizeof(int)); memset(sb_icon_flags, 0, sb_parts * sizeof(int)); memset(sb_menu_handles, 0, sb_parts * sizeof(HMENU)); + memset(sbTips, 0, sb_parts * sizeof(WCHAR *)); sb_parts = 0; diff --git a/src/pci.c b/src/pci.c index f56c3de85..b48ac2072 100644 --- a/src/pci.c +++ b/src/pci.c @@ -65,13 +65,13 @@ uint8_t elcr[2] = { 0, 0 }; void elcr_write(uint16_t port, uint8_t val, void *priv) { - pclog("ELCR%i: WRITE %02X\n", port & 1, val); + /* pclog("ELCR%i: WRITE %02X\n", port & 1, val); */ elcr[port & 1] = val; } uint8_t elcr_read(uint16_t port, void *priv) { - pclog("ELCR%i: READ %02X\n", port & 1, elcr[port & 1]); + /* pclog("ELCR%i: READ %02X\n", port & 1, elcr[port & 1]); */ return elcr[port & 1]; }