You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by xi...@apache.org on 2020/11/22 03:38:41 UTC
[incubator-nuttx] 03/22: fs/nxffs/nxffs_cache.c: Fix syslog formats
This is an automated email from the ASF dual-hosted git repository.
xiaoxiang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx.git
commit 35c30c2c4a45829bc035625c8b18d8494340c956
Author: YAMAMOTO Takashi <ya...@midokura.com>
AuthorDate: Sun Nov 22 09:41:25 2020 +0900
fs/nxffs/nxffs_cache.c: Fix syslog formats
---
fs/nxffs/nxffs_cache.c | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/fs/nxffs/nxffs_cache.c b/fs/nxffs/nxffs_cache.c
index 2995b9d..9581d66 100644
--- a/fs/nxffs/nxffs_cache.c
+++ b/fs/nxffs/nxffs_cache.c
@@ -44,6 +44,8 @@
#include <assert.h>
#include <errno.h>
#include <debug.h>
+#include <inttypes.h>
+#include <stdint.h>
#include <nuttx/mtd/mtd.h>
@@ -82,7 +84,8 @@ int nxffs_rdcache(FAR struct nxffs_volume_s *volume, off_t block)
nxfrd = MTD_BREAD(volume->mtd, block, 1, volume->cache);
if (nxfrd != 1)
{
- ferr("ERROR: Read block %d failed: %d\n", block, nxfrd);
+ ferr("ERROR: Read block %jd failed: %zu\n",
+ (intmax_t)block, nxfrd);
return -EIO;
}
@@ -117,7 +120,8 @@ int nxffs_wrcache(FAR struct nxffs_volume_s *volume)
nxfrd = MTD_BWRITE(volume->mtd, volume->cblock, 1, volume->cache);
if (nxfrd != 1)
{
- ferr("ERROR: Write block %d failed: %d\n", volume->cblock, nxfrd);
+ ferr("ERROR: Write block %jd failed: %zu\n",
+ (intmax_t)volume->cblock, nxfrd);
return -EIO;
}