mirror of
https://github.com/libretro/RetroArch
synced 2025-02-07 03:40:24 +00:00
path_relative_to: fix return in void function
This commit is contained in:
parent
e57f2bdd63
commit
d67a118ad4
@ -781,10 +781,13 @@ void path_relative_to(char *out, const char *path, const char *base, size_t size
|
||||
|
||||
#ifdef _WIN32
|
||||
/* For different drives, return absolute path */
|
||||
if (strlen(path) > 2 && strlen(base) > 2)
|
||||
if (path[1] == ':' && base[1] == ':')
|
||||
if (path[0] != base[0])
|
||||
return path;
|
||||
if (strlen(path) >= 2 && strlen(base) >= 2
|
||||
&& path[1] == ':' && base[1] == ':'
|
||||
&& path[0] != base[0])
|
||||
{
|
||||
out[0] = '\0';
|
||||
strlcat(out, path, size);
|
||||
}
|
||||
#endif
|
||||
|
||||
/* Trim common beginning */
|
||||
|
Loading…
x
Reference in New Issue
Block a user