buildroot.busybox.net archive mirror
 help / color / mirror / Atom feed
* [Buildroot] [PATCH 1/1] package/libuwsc: fix build with gcc 11
@ 2021-08-04  9:45 Fabrice Fontaine
  2021-08-04 21:19 ` Arnout Vandecappelle
  0 siblings, 1 reply; 2+ messages in thread
From: Fabrice Fontaine @ 2021-08-04  9:45 UTC (permalink / raw)
  To: buildroot; +Cc: Jianhui Zhao, Fabrice Fontaine

Fix the following build failure with gcc 11:

/tmp/instance-1/output-1/build/libuwsc-3.3.5/src/lua/uwsc_lua.c: In function 'uwsc_lua_on':
/tmp/instance-1/output-1/build/libuwsc-3.3.5/src/lua/uwsc_lua.c:177:5: error: this 'else' clause does not guard... [-Werror=misleading-indentation]
  177 |     else
      |     ^~~~
/tmp/instance-1/output-1/build/libuwsc-3.3.5/src/lua/uwsc_lua.c:180:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'else'
  180 |         return 0;
      |         ^~~~~~

Fixes:
 - http://autobuild.buildroot.org/results/1b031667e6d184493ea55ea6630272af4e475375

Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
---
 .../libuwsc/0002-fix-bad-indentation.patch    | 27 +++++++++++++++++++
 1 file changed, 27 insertions(+)
 create mode 100644 package/libuwsc/0002-fix-bad-indentation.patch

diff --git a/package/libuwsc/0002-fix-bad-indentation.patch b/package/libuwsc/0002-fix-bad-indentation.patch
new file mode 100644
index 0000000000..f33f944d06
--- /dev/null
+++ b/package/libuwsc/0002-fix-bad-indentation.patch
@@ -0,0 +1,27 @@
+From 8cb416140741a596235b8acc46b2b119b13ebfab Mon Sep 17 00:00:00 2001
+From: Rosen Penev <rosenp@gmail.com>
+Date: Tue, 6 Jul 2021 21:01:52 -0700
+Subject: [PATCH] fix bad indentation
+
+Fixes error with GCC11.
+
+[Retrieved from:
+https://github.com/zhaojh329/libuwsc/commit/8cb416140741a596235b8acc46b2b119b13ebfab]
+Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
+---
+ src/lua/uwsc_lua.c | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/src/lua/uwsc_lua.c b/src/lua/uwsc_lua.c
+index de6932e..84689fe 100644
+--- a/src/lua/uwsc_lua.c
++++ b/src/lua/uwsc_lua.c
+@@ -178,7 +178,7 @@ static int uwsc_lua_on(lua_State *L)
+     else
+         luaL_argcheck(L, false, 2, "available event name: open message error close");
+ 
+-	return 0;
++    return 0;
+ }
+ 
+ static int __uwsc_lua_send(lua_State *L, int op)
-- 
2.30.2

_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [Buildroot] [PATCH 1/1] package/libuwsc: fix build with gcc 11
  2021-08-04  9:45 [Buildroot] [PATCH 1/1] package/libuwsc: fix build with gcc 11 Fabrice Fontaine
@ 2021-08-04 21:19 ` Arnout Vandecappelle
  0 siblings, 0 replies; 2+ messages in thread
From: Arnout Vandecappelle @ 2021-08-04 21:19 UTC (permalink / raw)
  To: Fabrice Fontaine, buildroot; +Cc: Jianhui Zhao



On 04/08/2021 11:45, Fabrice Fontaine wrote:
> Fix the following build failure with gcc 11:
> 
> /tmp/instance-1/output-1/build/libuwsc-3.3.5/src/lua/uwsc_lua.c: In function 'uwsc_lua_on':
> /tmp/instance-1/output-1/build/libuwsc-3.3.5/src/lua/uwsc_lua.c:177:5: error: this 'else' clause does not guard... [-Werror=misleading-indentation]
>   177 |     else
>       |     ^~~~
> /tmp/instance-1/output-1/build/libuwsc-3.3.5/src/lua/uwsc_lua.c:180:9: note: ...this statement, but the latter is misleadingly indented as if it were guarded by the 'else'
>   180 |         return 0;
>       |         ^~~~~~
> 
> Fixes:
>  - http://autobuild.buildroot.org/results/1b031667e6d184493ea55ea6630272af4e475375
> 
> Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>

 Applied to master, thanks.

 Regards,
 Arnout

> ---
>  .../libuwsc/0002-fix-bad-indentation.patch    | 27 +++++++++++++++++++
>  1 file changed, 27 insertions(+)
>  create mode 100644 package/libuwsc/0002-fix-bad-indentation.patch
> 
> diff --git a/package/libuwsc/0002-fix-bad-indentation.patch b/package/libuwsc/0002-fix-bad-indentation.patch
> new file mode 100644
> index 0000000000..f33f944d06
> --- /dev/null
> +++ b/package/libuwsc/0002-fix-bad-indentation.patch
> @@ -0,0 +1,27 @@
> +From 8cb416140741a596235b8acc46b2b119b13ebfab Mon Sep 17 00:00:00 2001
> +From: Rosen Penev <rosenp@gmail.com>
> +Date: Tue, 6 Jul 2021 21:01:52 -0700
> +Subject: [PATCH] fix bad indentation
> +
> +Fixes error with GCC11.
> +
> +[Retrieved from:
> +https://github.com/zhaojh329/libuwsc/commit/8cb416140741a596235b8acc46b2b119b13ebfab]
> +Signed-off-by: Fabrice Fontaine <fontaine.fabrice@gmail.com>
> +---
> + src/lua/uwsc_lua.c | 2 +-
> + 1 file changed, 1 insertion(+), 1 deletion(-)
> +
> +diff --git a/src/lua/uwsc_lua.c b/src/lua/uwsc_lua.c
> +index de6932e..84689fe 100644
> +--- a/src/lua/uwsc_lua.c
> ++++ b/src/lua/uwsc_lua.c
> +@@ -178,7 +178,7 @@ static int uwsc_lua_on(lua_State *L)
> +     else
> +         luaL_argcheck(L, false, 2, "available event name: open message error close");
> + 
> +-	return 0;
> ++    return 0;
> + }
> + 
> + static int __uwsc_lua_send(lua_State *L, int op)
> 
_______________________________________________
buildroot mailing list
buildroot@busybox.net
http://lists.busybox.net/mailman/listinfo/buildroot

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-08-04 21:19 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-04  9:45 [Buildroot] [PATCH 1/1] package/libuwsc: fix build with gcc 11 Fabrice Fontaine
2021-08-04 21:19 ` Arnout Vandecappelle

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).