From cc80db955d0551c2456692da6176530dd27e08ed Mon Sep 17 00:00:00 2001 From: Dmitry Vyukov Date: Fri, 1 Oct 2021 16:01:47 +0200 Subject: executor: check for single-line compound statements Historically the code base does not use single-line compound statements ({} around single-line blocks). But there are few precedents creeped into already. Add a check to keep the code base consistent. --- executor/common_linux.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'executor/common_linux.h') diff --git a/executor/common_linux.h b/executor/common_linux.h index d80883729..972376165 100644 --- a/executor/common_linux.h +++ b/executor/common_linux.h @@ -2512,9 +2512,8 @@ static bool process_command_pkt(int fd, char* buf, ssize_t buf_size) { struct hci_command_hdr* hdr = (struct hci_command_hdr*)buf; if (buf_size < (ssize_t)sizeof(struct hci_command_hdr) || - hdr->plen != buf_size - sizeof(struct hci_command_hdr)) { + hdr->plen != buf_size - sizeof(struct hci_command_hdr)) failmsg("process_command_pkt: invalid size", "suze=%zx", buf_size); - } switch (hdr->opcode) { case HCI_OP_WRITE_SCAN_ENABLE: { -- cgit mrf-deployment