Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-9988

assertion in fastfat code on media change (i.e floppy)

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Fix Version/s: 0.4.5
    • Component/s: Filesystems
    • Labels:
    • Environment:

      VirtualBox 5.0

    • Module:
    • Sprint:
      January 2017

      Description

      There's a possible assertion case between floppy and fastfat drivers code when floppy media was changed and there were no actual volume mounting.

      Test code floppydetect.c (which is portion of actual usetup code) is attached. To trigger the issue you need to run
      floppydetect when virtual floppy image is on, and couple times more when it is off, without any other access to drive A:

      floppy.c
      http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/floppy.c?revision=63247&view=markup#l1015
      SignalMediaChanged(PDEVICE_OBJECT DeviceObject, PIRP Irp)

      /* If volume is not mounted, do NOT set verify and return STATUS_IO_DEVICE_ERROR */
      if(!(DeviceObject->Vpb->Flags & VPB_MOUNTED))

      { Irp->IoStatus.Status = STATUS_IO_DEVICE_ERROR; Irp->IoStatus.Information = 0; return; }

      SignalMediaChanged() may returns without setting IoSetHardErrorOrVerifyDevice(Irp, DeviceObject);

      while fastfat/blockdev.c
      http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/fastfat/blockdev.c?view=markup#l415

      always expect
      DeviceToVerify = IoGetDeviceToVerify(PsGetCurrentThread());
      to be set (not NULL)

      Possible solution is to check DeviceToVerify (patch attached).

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Heis Spiter Pierre Schweitzer
                Reporter:
                olegpro olegpro
              • Votes:
                1 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: