From: Andre Noll Date: Sat, 6 May 2017 15:40:38 +0000 (+0200) Subject: client: Silence a gcc-7.1,0 warning. X-Git-Tag: v0.6.1~81 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=72d4d4972fa22f5735f8b089035aca0a1effa424;hp=950e111e883e974b5326aa2e5aa3da363de40ced client: Silence a gcc-7.1,0 warning. This version of gcc complains because a case statement in client_pre_select() may fall through. The fallthrough is intentional, however, and this is annotated with a comment. gcc-7 scans the comments in a switch statement and suppresses the warning if it recognizes a comment which says that fallthrough is intended. But for this to happen, we must spell it correctly, and without whitespace. After this commit, gcc-7 compiles the tree with no warnings. --- diff --git a/client_common.c b/client_common.c index a06aaa00..39eb8b4c 100644 --- a/client_common.c +++ b/client_common.c @@ -90,7 +90,7 @@ static void client_pre_select(struct sched *s, void *context) else if (ret > 0) para_fd_set(ct->scc.fd, &s->wfds, &s->max_fileno); } - /* fall though */ + /* fallthrough */ case CL_EXECUTING: if (ct->btrn[0]) { ret = btr_node_status(ct->btrn[0], 0, BTR_NT_ROOT);