From e386bc496347e7f3ce53ed7d4e0f8d6a55c66129 Mon Sep 17 00:00:00 2001 From: twinaphex Date: Tue, 26 Jan 2016 01:27:23 +0100 Subject: [PATCH] Cleanup --- libretro-common/file/file_path.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/libretro-common/file/file_path.c b/libretro-common/file/file_path.c index 1a232e2204..02cd5d021a 100644 --- a/libretro-common/file/file_path.c +++ b/libretro-common/file/file_path.c @@ -462,12 +462,10 @@ void path_parent_dir(char *path) **/ const char *path_basename(const char *path) { - const char *last_hash = NULL; const char *last = find_last_slash(path); - - (void)last_hash; - #ifdef HAVE_COMPRESSION + const char *last_hash = NULL; + /* We cut either at the last hash or the last slash; whichever comes last */ last_hash = strchr(path,'#');