diff options
author | David Robillard <d@drobilla.net> | 2024-12-11 10:06:03 -0500 |
---|---|---|
committer | David Robillard <d@drobilla.net> | 2024-12-11 10:06:33 -0500 |
commit | 8874670463276073fe6cdb0bccd0d9a9a982b4c5 (patch) | |
tree | 3a95fee69e627c0bac27206b2db7de1fcf17abc0 /src | |
parent | 52048ee6db71982693cdeb603e725a867afd99e5 (diff) | |
download | zix-8874670463276073fe6cdb0bccd0d9a9a982b4c5.tar.gz zix-8874670463276073fe6cdb0bccd0d9a9a982b4c5.tar.bz2 zix-8874670463276073fe6cdb0bccd0d9a9a982b4c5.zip |
Fix clang and clang-tidy warnings on Windows
Diffstat (limited to 'src')
-rw-r--r-- | src/path.c | 2 | ||||
-rw-r--r-- | src/posix/filesystem_posix.c | 4 | ||||
-rw-r--r-- | src/posix/sem_posix.c | 3 | ||||
-rw-r--r-- | src/win32/win32_util.h | 4 |
4 files changed, 10 insertions, 3 deletions
@@ -1,4 +1,4 @@ -// Copyright 2007-2022 David Robillard <d@drobilla.net> +// Copyright 2007-2024 David Robillard <d@drobilla.net> // SPDX-License-Identifier: ISC #include <zix/path.h> diff --git a/src/posix/filesystem_posix.c b/src/posix/filesystem_posix.c index bb398c1..ea091e0 100644 --- a/src/posix/filesystem_posix.c +++ b/src/posix/filesystem_posix.c @@ -341,6 +341,9 @@ zix_canonical_path(ZixAllocator* const allocator, const char* const path) } zix_free(allocator, buffer); + +#else + (void)allocator; #endif return NULL; @@ -449,6 +452,7 @@ zix_current_path(ZixAllocator* const allocator) return current; #else + (void)allocator; return NULL; #endif diff --git a/src/posix/sem_posix.c b/src/posix/sem_posix.c index ea49db9..5b14e37 100644 --- a/src/posix/sem_posix.c +++ b/src/posix/sem_posix.c @@ -61,6 +61,9 @@ zix_sem_timed_wait(ZixSem* sem, { #if !USE_CLOCK_GETTIME || !USE_SEM_TIMEDWAIT + (void)sem; + (void)seconds; + (void)nanoseconds; return ZIX_STATUS_NOT_SUPPORTED; #else diff --git a/src/win32/win32_util.h b/src/win32/win32_util.h index 3123ef4..3ae2e2b 100644 --- a/src/win32/win32_util.h +++ b/src/win32/win32_util.h @@ -14,11 +14,11 @@ typedef const char ArgPathChar; /// Copy and convert a path argument if necessary ArgPathChar* -arg_path_new(ZixAllocator* const allocator, const char* const path); +arg_path_new(ZixAllocator* allocator, const char* path); /// Free a path from arg_path_new() if necessary void -arg_path_free(ZixAllocator* const allocator, ArgPathChar* const path); +arg_path_free(ZixAllocator* allocator, ArgPathChar* path); /// Convert from (user) UTF-8 to (Windows) UTF-16 wchar_t* |