From b950bf43ba1a6d64fe9664a34f253bf6ea39b820 Mon Sep 17 00:00:00 2001 From: Peter Veenstra Date: Sun, 28 May 2006 09:40:42 +0000 Subject: [PATCH] 2 small patches from h-a-l-9000. Joystick equimentbit. Don't change drive when there none mounted. Imported-from: https://svn.code.sf.net/p/dosbox/code-0/dosbox/trunk@2641 --- src/dos/dos_files.cpp | 4 ++-- src/ints/bios.cpp | 4 +++- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/dos/dos_files.cpp b/src/dos/dos_files.cpp index 0b1246b9..0eedde22 100644 --- a/src/dos/dos_files.cpp +++ b/src/dos/dos_files.cpp @@ -16,7 +16,7 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* $Id: dos_files.cpp,v 1.73 2006-04-23 14:20:57 c2woody Exp $ */ +/* $Id: dos_files.cpp,v 1.74 2006-05-28 09:40:42 qbix79 Exp $ */ #include #include @@ -49,7 +49,7 @@ Bit8u DOS_GetDefaultDrive(void) { } void DOS_SetDefaultDrive(Bit8u drive) { - if (drive<=DOS_DRIVES) dos.current_drive=drive; + if (drive<=DOS_DRIVES && Drives[drive]) dos.current_drive = drive; } bool DOS_MakeName(char * name,char * fullname,Bit8u * drive) { diff --git a/src/ints/bios.cpp b/src/ints/bios.cpp index d9751bfb..3efd14b2 100644 --- a/src/ints/bios.cpp +++ b/src/ints/bios.cpp @@ -16,7 +16,7 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -/* $Id: bios.cpp,v 1.60 2006-05-23 10:30:02 qbix79 Exp $ */ +/* $Id: bios.cpp,v 1.61 2006-05-28 09:40:42 qbix79 Exp $ */ #include "dosbox.h" #include "mem.h" @@ -988,6 +988,8 @@ public: } // PS2 mouse config |= 0x04; + // Gameport + config |= 0x1000; mem_writew(BIOS_CONFIGURATION,config); CMOS_SetRegister(0x14,config); //Should be updated on changes /* Setup extended memory size */