diff mbox series

[1/4] android: Fix build with GCC 10

Message ID 20200420120705.89691-1-szymon.janc@codecoup.pl (mailing list archive)
State Accepted
Delegated to: Luiz Von Dentz
Headers show
Series [1/4] android: Fix build with GCC 10 | expand

Commit Message

Szymon Janc April 20, 2020, 12:07 p.m. UTC
status and state are used to hold various enum types depending on test
and callback passed. Define them as int to avoid warnings about enum
assignment from invalid type.
---
 android/tester-main.h | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Comments

Brian Gix April 20, 2020, 4:41 p.m. UTC | #1
Hi Luiz,

Modulo my question about nul termination on patch 3/4,  This patchset resolves all of the GCC 10 build
error/warnings and, I think, should be applied.

On Mon, 2020-04-20 at 14:07 +0200, Szymon Janc wrote:
> status and state are used to hold various enum types depending on test
> and callback passed. Define them as int to avoid warnings about enum
> assignment from invalid type.
> ---
>  android/tester-main.h | 4 ++--
>  1 file changed, 2 insertions(+), 2 deletions(-)
> 
> diff --git a/android/tester-main.h b/android/tester-main.h
> index 8a7384c57..6bdfdbcdb 100644
> --- a/android/tester-main.h
> +++ b/android/tester-main.h
> @@ -653,8 +653,8 @@ struct map_inst_data {
>   * matching with expected step data.
>   */
>  struct bt_callback_data {
> -	bt_state_t state;
> -	bt_status_t status;
> +	int state;
> +	int status;
>  	int num_properties;
>  	bt_property_t *properties;
>  	bt_uuid_t *uuid;
Luiz Augusto von Dentz April 20, 2020, 6 p.m. UTC | #2
Hi Szymon,

On Mon, Apr 20, 2020 at 9:42 AM Gix, Brian <brian.gix@intel.com> wrote:
>
> Hi Luiz,
>
> Modulo my question about nul termination on patch 3/4,  This patchset resolves all of the GCC 10 build
> error/warnings and, I think, should be applied.
>
> On Mon, 2020-04-20 at 14:07 +0200, Szymon Janc wrote:
> > status and state are used to hold various enum types depending on test
> > and callback passed. Define them as int to avoid warnings about enum
> > assignment from invalid type.
> > ---
> >  android/tester-main.h | 4 ++--
> >  1 file changed, 2 insertions(+), 2 deletions(-)
> >
> > diff --git a/android/tester-main.h b/android/tester-main.h
> > index 8a7384c57..6bdfdbcdb 100644
> > --- a/android/tester-main.h
> > +++ b/android/tester-main.h
> > @@ -653,8 +653,8 @@ struct map_inst_data {
> >   * matching with expected step data.
> >   */
> >  struct bt_callback_data {
> > -     bt_state_t state;
> > -     bt_status_t status;
> > +     int state;
> > +     int status;
> >       int num_properties;
> >       bt_property_t *properties;
> >       bt_uuid_t *uuid;

Applied, thanks.
diff mbox series

Patch

diff --git a/android/tester-main.h b/android/tester-main.h
index 8a7384c57..6bdfdbcdb 100644
--- a/android/tester-main.h
+++ b/android/tester-main.h
@@ -653,8 +653,8 @@  struct map_inst_data {
  * matching with expected step data.
  */
 struct bt_callback_data {
-	bt_state_t state;
-	bt_status_t status;
+	int state;
+	int status;
 	int num_properties;
 	bt_property_t *properties;
 	bt_uuid_t *uuid;