[NTOS:IO] Finally remove the dreadful IopParseDevice() hack! \o/
authorHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Sat, 24 Nov 2018 21:36:32 +0000 (22:36 +0100)
committerPierre Schweitzer <pierre@reactos.org>
Sun, 25 Nov 2018 08:00:40 +0000 (09:00 +0100)
ntoskrnl/io/iomgr/file.c

index d8bb852..6b6b2e4 100644 (file)
@@ -582,29 +582,6 @@ IopParseDevice(IN PVOID ParseObject,
         /* Check if we can simply use a dummy file */
         UseDummyFile = ((OpenPacket->QueryOnly) || (OpenPacket->DeleteOnly));
 
-#if 1
-        /* FIXME: Small hack still exists, have to check why...
-         * This is triggered multiple times by usetup and then once per boot.
-         */
-        if (ExpInTextModeSetup &&
-            !(DirectOpen) &&
-            !(RemainingName->Length) &&
-            !(OpenPacket->RelatedFileObject) &&
-            ((wcsstr(CompleteName->Buffer, L"Harddisk")) ||
-            (wcsstr(CompleteName->Buffer, L"Floppy"))) &&
-            !(UseDummyFile))
-        {
-            DPRINT1("Using IopParseDevice() hack. Requested invalid attributes: %lx\n",
-            DesiredAccess & ~(SYNCHRONIZE |
-                              FILE_READ_ATTRIBUTES |
-                              READ_CONTROL |
-                              ACCESS_SYSTEM_SECURITY |
-                              WRITE_OWNER |
-                              WRITE_DAC));
-            DirectOpen = TRUE;
-        }
-#endif
-
         /* Check if this is a direct open */
         if (!(RemainingName->Length) &&
             !(OpenPacket->RelatedFileObject) &&