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 2021/02/04 18:06:10 UTC
[incubator-nuttx] 02/02: drivers:mtd:smart.c: entryname is declared
and should be under ifdef
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 dbec1cf6946708e486494cc6ffd92c5815448dfb
Author: Alexander Vasiljev <al...@gmail.com>
AuthorDate: Wed Feb 3 12:46:40 2021 +0300
drivers:mtd:smart.c: entryname is declared and should be under ifdef
---
drivers/mtd/smart.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/drivers/mtd/smart.c b/drivers/mtd/smart.c
index 3990af3..1f42daf 100644
--- a/drivers/mtd/smart.c
+++ b/drivers/mtd/smart.c
@@ -5945,9 +5945,9 @@ static int smart_fsck_directory(FAR struct smart_struct_s *dev,
(const char *) (cur + sizeof(struct smart_entry_header_s)),
dev->namesize);
entryname[dev->namesize] = '\0';
-#endif
finfo("Check entry (name=%s flags=%02x logsector=%02x)\n",
entryname, entry->flags, entry->firstsector);
+#endif
if (entry->flags & SMARTFS_DIRENT_ACTIVE)
{
@@ -5969,8 +5969,10 @@ static int smart_fsck_directory(FAR struct smart_struct_s *dev,
if (ret != OK)
{
+#ifdef CONFIG_DEBUG_FS_INFO
finfo("Remove entry (name=%s flags=%02x)\n",
entryname, entry->flags);
+#endif
if ((cur + (2 * entrysize)) <= bottom)
{