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

Regression : Drag'n'Drop pagefile.sys fails but creates empty folders of the same name

    XMLWordPrintable

Details

    • Bug
    • Resolution: Fixed
    • Major
    • 0.4.15
    • Shell
    • None

    Description

      reactos-bootcd-0.4.15-dev-7390-gafb132a-x86-gcc-lin-dbg

      This is a complement to CORE-19211 which focussed on non-filesystem objects

      • Open Explorer in C: drive and with system protected files made visible in settings
      • Drag'n'drop pagefile.sys on the Desktop ("move" operation, as "copy" is not affected)
      •  En empty folder of the same name is created.
      • Expected result (similar to Win2K3) : move fails gracefully (at SHFileOperationW level) without creating empty folder
      • The copy operations fails gracefully thanks to the following check that exists in copy_files and not in move_files. Due to this lack of check (1st problem), move_to_dir calls move_dir_to_dir due to wrong management of INVALID_FILE_ATTRIBUTES (2nd problem), which leads to the creation of a folder named "pagefile.sys".
      • This is caused by GetFileAttributesW returning INVALID_FILE_ATTRIBUTES on "c:\pagefile.sys" which is as expected

      if (flFrom->bAnyDontExist)
              return ERROR_SHELL_INTERNAL_FILE_NOT_FOUND; 

      Solution is : 

      • To add the bAnyDontExist check in move_files as in copy_files
      • To add a check in move_to_dir against INVALID_FILE_ATTRIBUTES to avoid creating a folder "by default" if passed with invalid file

      Fixed by : dragdropfixpart2.patch

      Attachments

        Issue Links

          Activity

            People

              katayama_hirofumi_mz Katayama Hirofumi MZ
              KRosUser KRosUser
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: