Make fallthrough explicit for libworker.c

The code currently doesn't compile with LLVM's `-Wimplicit-fallthrough` flag, but the attribute works for both GCC (>=7) and LLVM.
This commit is contained in:
Richard Barnes 2024-07-22 16:37:38 -07:00 committed by GitHub
parent 3af4e44646
commit f9bd35dcfa
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -292,7 +292,7 @@ libworker_do_cmd(struct libworker* w, uint8_t* msg, uint32_t len)
log_err("unknown command for bg worker %d", log_err("unknown command for bg worker %d",
(int)context_serial_getcmd(msg, len)); (int)context_serial_getcmd(msg, len));
/* and fall through to quit */ /* and fall through to quit */
/* fallthrough */ __attribute__((fallthrough));
case UB_LIBCMD_QUIT: case UB_LIBCMD_QUIT:
free(msg); free(msg);
comm_base_exit(w->base); comm_base_exit(w->base);