From 3bb0e20addddbbd3d5ab81ef954d3aba25128667 Mon Sep 17 00:00:00 2001 From: Ilya Shipitsin Date: Sun, 6 Jan 2019 23:44:23 +0500 Subject: [PATCH] src/Mayaqua/FileIO: remove unused function found by cppcheck [src/Mayaqua/FileIO.c:2082]: (style) The function 'FileRename' is never used. --- src/Mayaqua/FileIO.c | 11 ----------- src/Mayaqua/FileIO.h | 1 - 2 files changed, 12 deletions(-) diff --git a/src/Mayaqua/FileIO.c b/src/Mayaqua/FileIO.c index 9e089283..7a912411 100644 --- a/src/Mayaqua/FileIO.c +++ b/src/Mayaqua/FileIO.c @@ -2079,17 +2079,6 @@ void NormalizePath(char *dst, UINT size, char *src) } // Rename the file -bool FileRename(char *old_name, char *new_name) -{ - wchar_t *old_name_w = CopyStrToUni(old_name); - wchar_t *new_name_w = CopyStrToUni(new_name); - bool ret = FileRenameW(old_name_w, new_name_w); - - Free(old_name_w); - Free(new_name_w); - - return ret; -} bool FileRenameW(wchar_t *old_name, wchar_t *new_name) { wchar_t tmp1[MAX_SIZE]; diff --git a/src/Mayaqua/FileIO.h b/src/Mayaqua/FileIO.h index 452cb759..982f831a 100644 --- a/src/Mayaqua/FileIO.h +++ b/src/Mayaqua/FileIO.h @@ -307,7 +307,6 @@ IO *FileOpenEx(char *name, bool write_mode, bool read_lock); IO *FileOpenExW(wchar_t *name, bool write_mode, bool read_lock); void ConvertPathW(wchar_t *path); bool FileRenameInnerW(wchar_t *old_name, wchar_t *new_name); -bool FileRename(char *old_name, char *new_name); bool FileRenameW(wchar_t *old_name, wchar_t *new_name); void NormalizePath(char *dst, UINT size, char *src); void NormalizePathW(wchar_t *dst, UINT size, wchar_t *src);