[rtems commit] dosfs: Fix msdos_format()

Sebastian Huber sebh at rtems.org
Mon Dec 3 16:23:00 UTC 2012


Module:    rtems
Branch:    master
Commit:    9683b2721c749e4b02e99d48bbf8c6cb9d969529
Changeset: http://git.rtems.org/rtems/commit/?id=9683b2721c749e4b02e99d48bbf8c6cb9d969529

Author:    Ralf Kirchner <ralf.kirchner at embedded-brains.de>
Date:      Wed Oct 31 11:08:09 2012 +0100

dosfs: Fix msdos_format()

For FAT32 msdos_format() used to initialize first FAT entries to
non-zero values only if a volume label was given.  Absence of these
entries made mounting such a FAT32 volume fail.

---

 cpukit/libfs/src/dosfs/msdos_format.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/cpukit/libfs/src/dosfs/msdos_format.c b/cpukit/libfs/src/dosfs/msdos_format.c
index 305cec9..1c31b98 100644
--- a/cpukit/libfs/src/dosfs/msdos_format.c
+++ b/cpukit/libfs/src/dosfs/msdos_format.c
@@ -1063,7 +1063,7 @@ int msdos_format
    * write FAT entry 1 as EOC
    * allocate directory in a FAT32 FS
    */
-  if ((ret_val == 0) && fmt_params.VolLabel_present){
+  if (ret_val == 0) {
     /*
      * empty sector: all clusters are free/do not link further on
      */




More information about the vc mailing list