summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndreas Schneider <asn@cryptomilk.org>2023-01-29 15:54:07 +0100
committerAndreas Schneider <asn@cryptomilk.org>2023-02-01 08:38:44 +0100
commit91b66f83c8edcce97881bf706a9111b731461225 (patch)
tree76cba2f451c6cabcc07df6476ac32fdf53b01429
parenta6b7cbca1cbc1d6d96efa8c9fc8f560ee0a135d1 (diff)
downloadcmocka-91b66f83c8edcce97881bf706a9111b731461225.zip
cmocka-91b66f83c8edcce97881bf706a9111b731461225.tar.gz
cmocka-91b66f83c8edcce97881bf706a9111b731461225.tar.bz2
example: Fix pos value as snprintf returns an int
-rw-r--r--example/mock/uptime/uptime.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/example/mock/uptime/uptime.c b/example/mock/uptime/uptime.c
index 77776a7..f92aaff 100644
--- a/example/mock/uptime/uptime.c
+++ b/example/mock/uptime/uptime.c
@@ -26,7 +26,7 @@
static char *calc_uptime(void)
{
uint32_t up_minutes, up_hours, up_days, up_weeks, up_years;
- ssize_t pos = 0;
+ int pos = 0;
size_t comma = 0;
double uptime_secs, idle_secs;
char buf[1024] = {0};