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 2022/04/13 02:16:50 UTC
[incubator-nuttx] 03/04: libc/strptime: fix warning unused-value
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 96ea9b71ed906f5941705a17de4136e873dcdf02
Author: Xiang Xiao <xi...@xiaomi.com>
AuthorDate: Wed Dec 15 13:42:15 2021 +0800
libc/strptime: fix warning unused-value
warning: value computed is not used [-Wunused-value]
Signed-off-by: Xiang Xiao <xi...@xiaomi.com>
Signed-off-by: anjiahao <an...@xiaomi.com>
---
libs/libc/time/lib_strptime.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libs/libc/time/lib_strptime.c b/libs/libc/time/lib_strptime.c
index 7e4d8828e8..e983a42679 100644
--- a/libs/libc/time/lib_strptime.c
+++ b/libs/libc/time/lib_strptime.c
@@ -413,8 +413,8 @@ _conv_num(const unsigned char **buf, int *dest, int llim, int ulim)
int result = 0;
int rulim = ulim;
- while (ispace(**buf))
- *buf++;
+ while (isspace(**buf))
+ (*buf)++;
if (**buf < '0' || **buf > '9')
return (0);