[ros-diffs] [hpoussin] 43002: Do not leak device descriptors in case of error

hpoussin at svn.reactos.org hpoussin at svn.reactos.org
Sun Sep 6 16:21:01 CEST 2009


Author: hpoussin
Date: Sun Sep  6 16:21:00 2009
New Revision: 43002

URL: http://svn.reactos.org/svn/reactos?rev=43002&view=rev
Log:
Do not leak device descriptors in case of error

Modified:
    trunk/reactos/boot/freeldr/freeldr/fs/fs.c

Modified: trunk/reactos/boot/freeldr/freeldr/fs/fs.c
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/boot/freeldr/freeldr/fs/fs.c?rev=43002&r1=43001&r2=43002&view=diff
==============================================================================
--- trunk/reactos/boot/freeldr/freeldr/fs/fs.c [iso-8859-1] (original)
+++ trunk/reactos/boot/freeldr/freeldr/fs/fs.c [iso-8859-1] Sun Sep  6 16:21:00 2009
@@ -332,6 +332,7 @@
                 if (!FileData[DeviceId].FileFuncTable)
                 {
                     /* Error, unable to detect file system */
+                    pDevice->FuncTable->Close(DeviceId);
                     FileData[DeviceId].FuncTable = NULL;
                     return ENODEV;
                 }




More information about the Ros-diffs mailing list