[rtems commit] dosfs: Fix print format string

Sebastian Huber sebh at rtems.org
Tue May 29 14:15:51 UTC 2012


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

Author:    Sebastian Huber <sebastian.huber at embedded-brains.de>
Date:      Tue May 29 16:16:44 2012 +0200

dosfs: Fix print format string

---

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

diff --git a/cpukit/libfs/src/dosfs/msdos_format.c b/cpukit/libfs/src/dosfs/msdos_format.c
index 2a9d090..9af86b7 100644
--- a/cpukit/libfs/src/dosfs/msdos_format.c
+++ b/cpukit/libfs/src/dosfs/msdos_format.c
@@ -33,6 +33,7 @@
 #include <stdlib.h>
 #include <stdio.h>
 #include <ctype.h>
+#include <inttypes.h>
 
 #include <rtems/libio_.h>
 
@@ -400,7 +401,7 @@ static int msdos_format_determine_fmt_params
   if (ret_val == 0) {
     total_size = fmt_params->bytes_per_sector * fmt_params->totl_sector_cnt;
     msdos_format_printf (rqdata, MSDOS_FMT_INFO_LEVEL_DETAIL,
-                         "bytes per sector: %d\ntotal sectors: %d\ntotal size: %lu\n",
+                         "bytes per sector: %" PRIu32 "\ntotal sectors: %" PRIu32 "\ntotal size: %" PRIu64 "\n",
                          fmt_params->bytes_per_sector, fmt_params->totl_sector_cnt, total_size);
   }
 




More information about the vc mailing list