Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/littlefs-project/littlefs.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDamien George <damien.p.george@gmail.com>2018-06-08 04:24:27 +0300
committerChristopher Haster <chaster@utexas.edu>2018-07-02 18:29:19 +0300
commit51346b8bf4146cc145c2cefce9928b03fa9f4c8c (patch)
treef6088a3d7de73fc903bfa9762c0aca9f911ec59c /lfs_util.h
parent93a2e0bbe53e741f468bd84e75a2f894aa6158e3 (diff)
Fixed shadowed variable warnings
- Fixed shadowed variable warnings in lfs_dir_find. - Fixed unused parameter warnings when LFS_NO_MALLOC is enabled. - Added extra warning flags to CFLAGS. - Updated tests so they don't shadow the "size" variable for -Wshadow
Diffstat (limited to 'lfs_util.h')
-rw-r--r--lfs_util.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/lfs_util.h b/lfs_util.h
index 51005dc..d61c545 100644
--- a/lfs_util.h
+++ b/lfs_util.h
@@ -158,6 +158,7 @@ static inline void *lfs_malloc(size_t size) {
#ifndef LFS_NO_MALLOC
return malloc(size);
#else
+ (void)size;
return NULL;
#endif
}
@@ -166,6 +167,8 @@ static inline void *lfs_malloc(size_t size) {
static inline void lfs_free(void *p) {
#ifndef LFS_NO_MALLOC
free(p);
+#else
+ (void)p;
#endif
}