From mboxrd@z Thu Jan 1 00:00:00 1970 From: Stas Sergeev Subject: Re: unable to boot as user Date: Mon, 17 Jun 2002 01:51:47 +0400 Sender: linux-msdos-owner@vger.kernel.org Message-ID: <3D0D0873.9020805@yahoo.com> Reply-To: stas.orel@mailcity.com Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------040305040900000203070108" Return-path: List-Id: To: linux-msdos@vger.kernel.org Cc: Baurjan Ismagulov This is a multi-part message in MIME format. --------------040305040900000203070108 Content-Type: text/plain; charset=KOI8-R; format=flowed Content-Transfer-Encoding: 7bit Hello. Baurjan Ismagulov wrote: > I've thought about that, but was not sure whether that was indended > behaviour for bootoff. That is intended behaviour for bootoff but since you don't use bootoff... > however, for some > reason, dosemu disables a: after booting, which results in "Current > drive is no longer valid>" prompt (I don't use bootoff) Yep, I can see something similar here. > which is kind > of unexpected -- all I needed floppy for was doing "sys c:" and copying > a couple of files to c:. Agreed that it is confusing, but I don't see any clear logic to handle this setuation. What I can propose is only the attached hack. Does it fix your problems this time? --------------040305040900000203070108 Content-Type: text/plain; name="floppy.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="floppy.diff" --- src/base/misc/disks.c Tue Mar 19 00:58:12 2002 +++ src/base/misc/disks.c Fri Jun 14 23:17:10 2002 @@ -891,6 +891,12 @@ else dp->rdonly = dp->wantrdonly; } + if (!FDISKS && use_bootdisk) { + /* if we don't have any configured floppies, we have to use bootdisk instead */ + memcpy(&disktab[0], &bootdisk, sizeof(bootdisk)); + FDISKS++; /* now we have one */ + } + /* * Open hard disks */ @@ -1011,10 +1017,9 @@ int checkdp_val; disk = LO(dx); - if (disk < FDISKS) { - if (!disk && use_bootdisk) - dp = &bootdisk; - else + if (!disk && use_bootdisk) + dp = &bootdisk; + else if (disk < FDISKS) { dp = &disktab[disk]; switch (HI(ax)) { #define DISKETTE_MOTOR_TIMEOUT (*((unsigned char *)0x440)) --------------040305040900000203070108--