mirror of
https://github.com/libretro/RetroArch
synced 2025-03-03 04:14:00 +00:00
path_get_extension - fix regression
This commit is contained in:
parent
fbae4efc97
commit
a2cb3f60a4
@ -286,8 +286,9 @@ const char *path_get_archive_delim(const char *path)
|
||||
*/
|
||||
const char *path_get_extension(const char *path)
|
||||
{
|
||||
if (!string_is_empty(path))
|
||||
return strrchr(path_basename(path), '.') + 1;
|
||||
const char *ext;
|
||||
if (!string_is_empty(path) && ((ext = strrchr(path_basename(path), '.'))))
|
||||
return ext + 1;
|
||||
return "";
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user