You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nuttx.apache.org by ag...@apache.org on 2020/03/13 19:14:22 UTC

[incubator-nuttx-apps] branch master updated: apps/system/cle: Fix error when compiling with C89 compiler.

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

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


The following commit(s) were added to refs/heads/master by this push:
     new c742373  apps/system/cle:  Fix error when compiling with C89 compiler.
c742373 is described below

commit c742373efc1634aab01390691b8384887ad4cb4d
Author: Gregory Nutt <gn...@nuttx.org>
AuthorDate: Fri Mar 13 11:35:03 2020 -0600

    apps/system/cle:  Fix error when compiling with C89 compiler.
---
 system/cle/cle.c | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/system/cle/cle.c b/system/cle/cle.c
index 42272f3..f515699 100644
--- a/system/cle/cle.c
+++ b/system/cle/cle.c
@@ -655,7 +655,8 @@ static bool cle_opentext(FAR struct cle_s *priv, uint16_t pos,
  *
  ****************************************************************************/
 
-static void cle_closetext(FAR struct cle_s *priv, uint16_t pos, uint16_t size)
+static void cle_closetext(FAR struct cle_s *priv, uint16_t pos,
+                          uint16_t size)
 {
   int i;
 
@@ -798,6 +799,9 @@ static int cle_editloop(FAR struct cle_s *priv)
 
   for (; ; )
     {
+#if  1 /* Perhaps here should be a config switch */
+      char state = 0;
+#endif
       int ch;
 
       /* Make sure that the display reflects the current state */
@@ -812,8 +816,6 @@ static int cle_editloop(FAR struct cle_s *priv)
        * home/end, del
        */
 
-      char state = 0;
-
       /* loop till we have a ch */
 
       for (; ; )