Project

General

Profile

Bug #9161

libeti: this statement may fall through

Added by Toomas Soome almost 2 years ago. Updated almost 2 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
lib - userland libraries
Start date:
2018-02-21
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

Issue found by gcc 7 build:

    ../common/regex.c: In function '__advance':
    ../common/regex.c:175:3: error: this statement may fall through [-Werror=implicit-fallthrough=]
       (void) __xpop(0);
       ^~~~~~~~~~~~~~~~
    ../common/regex.c:176:2: note: here
      case EGRP|PLUS:
      ^~~~
    ../common/regex.c:277:6: error: this statement may fall through [-Werror=implicit-fallthrough=]
       if (*lp++ == '\0')
          ^
    ../common/regex.c:279:2: note: here
      case CDOT|STAR:
      ^~~~
    ../common/regex.c:285:6: error: this statement may fall through [-Werror=implicit-fallthrough=]
       if (*lp++ != *ep)
          ^
    ../common/regex.c:287:2: note: here
      case CCHR|STAR:
      ^~~~
    ../common/regex.c:297:6: error: this statement may fall through [-Werror=implicit-fallthrough=]
       if (!(lp = (char *)__advance(lp, ep+1)))
          ^
    ../common/regex.c:299:2: note: here
      case SGRP|A768:
      ^~~~
    ../common/regex.c:315:6: error: this statement may fall through [-Werror=implicit-fallthrough=]
       if (!__cclass(ep, *lp++, ep[-1] == (CCL | PLUS)))
          ^
    ../common/regex.c:317:2: note: here
      case CCL|STAR:
      ^~~~
    cc1: all warnings being treated as errors

History

#1

Updated by Electric Monk almost 2 years ago

  • % Done changed from 90 to 100
  • Status changed from In Progress to Closed

git commit 02b0e3b7c418f908fdce638a840f8d57e03e1346

commit  02b0e3b7c418f908fdce638a840f8d57e03e1346
Author: Toomas Soome <tsoome@me.com>
Date:   2018-02-23T15:37:20.000Z

    9161 libeti: this statement may fall through
    Reviewed by: C Fraire <cfraire@me.com>
    Reviewed by: Andy Fiddaman <omnios@citrus-it.co.uk>
    Approved by: Dan McDonald <danmcd@joyent.com>

Also available in: Atom PDF