Skip to content
This repository has been archived by the owner on Jul 2, 2018. It is now read-only.

Commit

Permalink
fc_sort: avoid compiler warning/error
Browse files Browse the repository at this point in the history
Fix a "-Werror=implicit-fallthrough" compiler warning/error on
the switch statement.

This third version (v3) fixes a bug introduced in the first
version and improves the style over the second version.

Signed-off-by: Guido Trentalancia <guido at trentalancia.com>
  • Loading branch information
Guido Trentalancia authored and pebenito committed Jun 7, 2017
1 parent 0131196 commit 89b53fa
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions support/fc_sort.c
Expand Up @@ -292,14 +292,16 @@ void fc_fill_data(file_context_node_t *fc_node)
/* If a escape character is found,
* skip the next character. */
c++;
break;
default:
/* If no meta character has been found yet,
* add one to the stem length. */
if (!fc_node->meta)
fc_node->stem_len++;
break;
}

/* If no meta character has been found yet,
* add one to the stem length. */
if (!fc_node->meta)
fc_node->stem_len++;

fc_node->str_len++;
c++;
}
Expand Down

0 comments on commit 89b53fa

Please sign in to comment.