[NTFS] When reading $I30 attribute fails, stop the rename operation.
authorPierre Schweitzer <pierre@reactos.org>
Sat, 14 Apr 2018 09:39:33 +0000 (11:39 +0200)
committerPierre Schweitzer <pierre@reactos.org>
Sat, 14 Apr 2018 09:43:57 +0000 (11:43 +0200)
This makes the function return the error instead of continuing and
performing use-after-frees operations.
This is likely to be a forgotten return!

CID 14342541434268

drivers/filesystems/ntfs/mft.c

index 515abf7..24f28e0 100644 (file)
@@ -1662,6 +1662,7 @@ UpdateFileNameRecord(PDEVICE_EXTENSION Vcb,
         ExFreePoolWithTag(IndexRecord, TAG_NTFS);
         ReleaseAttributeContext(IndexRootCtx);
         ExFreeToNPagedLookasideList(&Vcb->FileRecLookasideList, MftRecord);
+        return Status;
     }
 
     IndexRoot = (PINDEX_ROOT_ATTRIBUTE)IndexRecord;