Project

General

Profile

Bug #3556

OsmoSGSN fails --enable-werror on gcc >= 7

Added by laforge 3 months ago. Updated 3 months ago.

Status:
Closed
Priority:
High
Assignee:
Category:
-
Target version:
-
Start date:
09/16/2018
Due date:
% Done:

100%

Spec Reference:

Description

When I try to build osmo-sgsn with -Werror, I get

gprs_gmm_attach.c: In function ‘st_auth_on_enter’:
gprs_gmm_attach.c:148:34: error: increment of a boolean expression [-Werror=bool-operation]
   ctx->gmm_att_req.auth_reattempt++;
                                  ^~
gprs_gmm_attach.c: In function ‘st_auth’:
gprs_gmm_attach.c:163:39: error: comparison of constant ‘1’ with boolean expression is always true [-Werror=bool-compare]
   if (ctx->gmm_att_req.auth_reattempt <= 1)
                                       ^~

The big question now is : How did this ever pass build testing? But let's look at that in another issue...

History

#1 Updated by laforge 3 months ago

  • Priority changed from Urgent to High

Ok, it seems like only gcc >= 7 has -Werror=bool-operation, while debian stretch (which we use for gerrit + master build jobs) uses gcc-6.x

Nevertheless, this is a bug that needs to be fixed.

#2 Updated by laforge 3 months ago

  • Subject changed from OsmoSGSN fails --enable-werror to OsmoSGSN fails --enable-werror on gcc >= 7

#3 Updated by lynxis 3 months ago

  • Status changed from New to In Progress
  • % Done changed from 0 to 90

#4 Updated by lynxis 3 months ago

  • Status changed from In Progress to Closed

#5 Updated by lynxis 3 months ago

  • % Done changed from 90 to 100

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 48.8 MB)