Skip to content

Commit c6a06ec

Browse files
dschoGit for Windows Build Agent
authored andcommitted
mingw: fix compile warning when building without RUNTIME_PREFIX
Signed-off-by: Johannes Schindelin <[email protected]>
1 parent a991463 commit c6a06ec

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

compat/mingw.c

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3650,11 +3650,14 @@ int xwcstoutf(char *utf, const wchar_t *wcs, size_t utflen)
36503650
}
36513651

36523652
#ifdef ENSURE_MSYSTEM_IS_SET
3653-
static size_t append_system_bin_dirs(char *path, size_t size)
3654-
{
36553653
#if !defined(RUNTIME_PREFIX) || !defined(HAVE_WPGMPTR)
3654+
static size_t append_system_bin_dirs(char *path UNUSED, size_t size UNUSED)
3655+
{
36563656
return 0;
3657+
}
36573658
#else
3659+
static size_t append_system_bin_dirs(char *path, size_t size)
3660+
{
36583661
char prefix[32768];
36593662
const char *slash;
36603663
size_t len = xwcstoutf(prefix, _wpgmptr, sizeof(prefix)), off = 0;
@@ -3686,9 +3689,9 @@ static size_t append_system_bin_dirs(char *path, size_t size)
36863689
off += xsnprintf(path + off, size - off,
36873690
"%.*s\\usr\\bin;", (int)len, prefix);
36883691
return off;
3689-
#endif
36903692
}
36913693
#endif
3694+
#endif
36923695

36933696
static int is_system32_path(const char *path)
36943697
{

0 commit comments

Comments
 (0)