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/03/22 03:52:53 UTC

[incubator-nuttx-apps] branch master updated (960e634 -> 017f5ed)

This is an automated email from the ASF dual-hosted git repository.

xiaoxiang pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-nuttx-apps.git.


    from 960e634  nsh/builtin: Ignore the child status if run the application on background.
     new 331fd61  examples/qencoder/qe_main.c: Fix printf() format specifier
     new 017f5ed  examples/qencoder/qe_main.c: Fix nxstyle errors

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 examples/qencoder/qe_main.c | 9 ++++++---
 1 file changed, 6 insertions(+), 3 deletions(-)

[incubator-nuttx-apps] 01/02: examples/qencoder/qe_main.c: Fix printf() format specifier

Posted by xi...@apache.org.
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-apps.git

commit 331fd61115bfad22ff839b19b2769d25da604a86
Author: Nathan Hartman <59...@users.noreply.github.com>
AuthorDate: Fri Mar 19 16:05:53 2021 -0400

    examples/qencoder/qe_main.c: Fix printf() format specifier
    
    examples/qencoder/qe_main.c:
    
        * main(): Call to printf() had "%d" but argument was
          int32_t, leading to compiler warning. Change format
          specifier to PRIi32 (suggested by Gregory Nutt).
---
 examples/qencoder/qe_main.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/examples/qencoder/qe_main.c b/examples/qencoder/qe_main.c
index e7bd5ca..8306a4d 100644
--- a/examples/qencoder/qe_main.c
+++ b/examples/qencoder/qe_main.c
@@ -48,6 +48,7 @@
 #include <string.h>
 #include <fcntl.h>
 #include <limits.h>
+#include <inttypes.h>
 #include <errno.h>
 #include <debug.h>
 
@@ -300,7 +301,7 @@ int main(int argc, FAR char *argv[])
 
       else
         {
-          printf("qe_main: %3d. %d\n", nloops+1, position);
+          printf("qe_main: %3d. %" PRIi32 "\n", nloops + 1, position);
         }
 
       /* Delay a little bit */

[incubator-nuttx-apps] 02/02: examples/qencoder/qe_main.c: Fix nxstyle errors

Posted by xi...@apache.org.
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-apps.git

commit 017f5ed65c72b1dfcb2fb32c93424c37ecb6bd12
Author: Nathan Hartman <59...@users.noreply.github.com>
AuthorDate: Fri Mar 19 16:08:04 2021 -0400

    examples/qencoder/qe_main.c: Fix nxstyle errors
---
 examples/qencoder/qe_main.c | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/examples/qencoder/qe_main.c b/examples/qencoder/qe_main.c
index 8306a4d..27cb0f8 100644
--- a/examples/qencoder/qe_main.c
+++ b/examples/qencoder/qe_main.c
@@ -1,5 +1,5 @@
 /****************************************************************************
- * examples/qe/qe_main.c
+ * apps/examples/qencoder/qe_main.c
  *
  *   Copyright (C) 2012 Gregory Nutt. All rights reserved.
  *   Author: Gregory Nutt <gn...@nuttx.org>
@@ -279,7 +279,9 @@ int main(int argc, FAR char *argv[])
    */
 
   printf("qe_main: Number of samples: %u\n", g_qeexample.nloops);
-  for (nloops = 0; !g_qeexample.nloops || nloops < g_qeexample.nloops; nloops++)
+  for (nloops = 0;
+       !g_qeexample.nloops || nloops < g_qeexample.nloops;
+       nloops++)
     {
       /* Flush any output before the loop entered or from the previous pass
        * through the loop.