diff --git a/bochs/bxthread.h b/bochs/bxthread.h index 4a3a16716..1b54f9f07 100644 --- a/bochs/bxthread.h +++ b/bochs/bxthread.h @@ -30,7 +30,7 @@ #include #include -#define BX_THREAD_VAR(name) SDL_Thread* (name) = NULL +#define BX_THREAD_VAR(name) SDL_Thread* name = NULL #define BX_THREAD_FUNC(name,arg) static int name(void* arg) #define BX_THREAD_EXIT return 0 #if BX_WITH_SDL2 @@ -42,7 +42,7 @@ #endif #define BX_LOCK(mutex) SDL_LockMutex(mutex) #define BX_UNLOCK(mutex) SDL_UnlockMutex(mutex) -#define BX_MUTEX(mutex) SDL_mutex (*mutex) +#define BX_MUTEX(mutex) SDL_mutex *mutex #define BX_INIT_MUTEX(mutex) mutex = SDL_CreateMutex() #define BX_FINI_MUTEX(mutex) SDL_DestroyMutex(mutex) #define BX_MSLEEP(val) SDL_Delay(val) diff --git a/bochs/gui/win32_enh_dbg_osdep.cc b/bochs/gui/win32_enh_dbg_osdep.cc index 54b0a8706..be58f11e7 100644 --- a/bochs/gui/win32_enh_dbg_osdep.cc +++ b/bochs/gui/win32_enh_dbg_osdep.cc @@ -1269,14 +1269,14 @@ LRESULT CALLBACK B_WP(HWND hh,UINT mm,WPARAM ww,LPARAM ll) DefFont = (HFONT)GetStockObject(DEFAULT_GUI_FONT); // Register Window - char* txt0[] = {"Reg Name","Hex Value","Decimal"}; - LV_COLUMN lvc = {LVCF_SUBITEM | LVCF_TEXT,LVCFMT_LEFT,0,txt0[0]}; + const char* txt0[] = {"Reg Name","Hex Value","Decimal"}; + LV_COLUMN lvc = {LVCF_SUBITEM | LVCF_TEXT,LVCFMT_LEFT,0, (char*)txt0[0]}; hL[REG_WND] = CreateWindowEx(0,"sLV","",LVStyle[0],0,0,100,100,hh,(HMENU)1001,GetModuleHandle(0),0); // Note; WM_CREATE only happens once, so don't bother eliminating these SendMessage macros ListView_InsertColumn(hL[REG_WND],0,&lvc); - lvc.pszText = txt0[1]; + lvc.pszText = (char*)txt0[1]; ListView_InsertColumn(hL[REG_WND],1,&lvc); - lvc.pszText = txt0[2]; + lvc.pszText = (char*)txt0[2]; ListView_InsertColumn(hL[REG_WND],2,&lvc); // Enable the groupID's for the register window @@ -1310,13 +1310,13 @@ LRESULT CALLBACK B_WP(HWND hh,UINT mm,WPARAM ww,LPARAM ll) // Asm Window hL[ASM_WND] = CreateWindowEx(0,"sLV","",LVStyle[1] | WS_BORDER,0,0,1,1,hh,(HMENU)1000,GetModuleHandle(0),0); CurCenterList = 1; // ASM window starts with the border - char* txt3[] = {"L.Address","Bytes","Mnemonic"}; + const char* txt3[] = {"L.Address","Bytes","Mnemonic"}; - lvc.pszText = txt3[0]; + lvc.pszText = (char*)txt3[0]; ListView_InsertColumn(hL[ASM_WND],0,&lvc); - lvc.pszText = txt3[1]; + lvc.pszText = (char*)txt3[1]; ListView_InsertColumn(hL[ASM_WND],1,&lvc); - lvc.pszText = txt3[2]; + lvc.pszText = (char*)txt3[2]; ListView_InsertColumn(hL[ASM_WND],2,&lvc); // SendMessage(hL[ASM_WND], LVM_SETEXTENDEDLISTVIEWSTYLE, LVS_EX_FULLROWSELECT | LVS_EX_DOUBLEBUFFER, // LVS_EX_FULLROWSELECT | LVS_EX_DOUBLEBUFFER);