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 2023/10/06 09:25:30 UTC

[nuttx-apps] 01/02: adjtime: Fix wrong printf format when using CONFIG_SYSTEM_TIME64

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/nuttx-apps.git

commit c340d735eca8e6f6ea83cd3db2c9b0723717268e
Author: Petteri Aimonen <jp...@git.mail.kapsi.fi>
AuthorDate: Thu Sep 28 13:46:19 2023 +0300

    adjtime: Fix wrong printf format when using CONFIG_SYSTEM_TIME64
---
 examples/adjtime/adjtime_main.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/examples/adjtime/adjtime_main.c b/examples/adjtime/adjtime_main.c
index 26e9a481d..a897fa153 100644
--- a/examples/adjtime/adjtime_main.c
+++ b/examples/adjtime/adjtime_main.c
@@ -148,7 +148,7 @@ int main(int argc, FAR char *argv[])
   parse_args(&delta, argc, argv);
 
   printf("Delta time is %ld seconds and %ld micro seconds.\n",
-         delta.tv_sec, delta.tv_usec);
+         (long)delta.tv_sec, delta.tv_usec);
 
   /* Call adjtime function. */
 
@@ -160,7 +160,7 @@ int main(int argc, FAR char *argv[])
   else
     {
       printf("Returned olddelta is %ld seconds and %ld micro seconds.\n",
-             olddelta.tv_sec, olddelta.tv_usec);
+             (long)olddelta.tv_sec, olddelta.tv_usec);
     }
 
   return ret;