tidy: address some clang-tidy lints

This commit is contained in:
Utkarsh Verma 2025-10-08 11:06:48 +02:00
commit 38cadc6427
No known key found for this signature in database
GPG key ID: 7A4885A7162BDF20
2 changed files with 4 additions and 2 deletions

View file

@ -5,7 +5,7 @@
#include <stdbool.h> #include <stdbool.h>
#include <stdio.h> #include <stdio.h>
cli_arguments cli_parse_arguments(const char *const argv[], const int argc) { cli_arguments cli_parse_arguments(const char* const argv[], const int argc) {
errno = 0; errno = 0;
cli_arguments args = { cli_arguments args = {
.is_debug_mode = false, .is_debug_mode = false,
@ -13,7 +13,7 @@ cli_arguments cli_parse_arguments(const char *const argv[], const int argc) {
int opt = -1; int opt = -1;
opterr = 0; // Suppress getopt's built-in invalid opt message opterr = 0; // Suppress getopt's built-in invalid opt message
while ((opt = getopt(argc, (char *const *)argv, "dh")) != -1) { while ((opt = getopt(argc, (char* const*)argv, "dh")) != -1) {
switch (opt) { switch (opt) {
case 'd': case 'd':
args.is_debug_mode = true; args.is_debug_mode = true;

View file

@ -109,6 +109,8 @@ int signal_handler_process(signal_handler *const handler, timer *const timer) {
// fall through // fall through
case SIGINT: case SIGINT:
return 1; return 1;
default:
break;
} }
for (unsigned short i = 0; i < handler->block_count; ++i) { for (unsigned short i = 0; i < handler->block_count; ++i) {