From 888ba881ec935caf7dd2d669ca0d8014363f9de5 Mon Sep 17 00:00:00 2001 From: Alcaro Date: Fri, 20 Nov 2015 16:33:21 +0100 Subject: [PATCH] No need to free a known null... --- dynamic.c | 11 +++++------ libretro-common/file/file_path.c | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/dynamic.c b/dynamic.c index 89015fdb22..9f96d2f9f0 100644 --- a/dynamic.c +++ b/dynamic.c @@ -618,8 +618,8 @@ static bool rarch_game_specific_options(char **output) if (core_name[0] == '\0' || game_name[0] == '\0') return false; - RARCH_LOG("Per-game Options: core name: %s\n", core_name); - RARCH_LOG("Per-game Options: game name: %s\n", game_name); + RARCH_LOG("Per-Game Options: core name: %s\n", core_name); + RARCH_LOG("Per-Game Options: game name: %s\n", game_name); /* Config directory: config_directory. @@ -631,7 +631,7 @@ static bool rarch_game_specific_options(char **output) fill_pathname_basedir(config_directory, global->path.config, PATH_MAX_LENGTH); else { - RARCH_WARN("Per-game Options: no config directory set\n"); + RARCH_WARN("Per-Game Options: no config directory set\n"); return false; } @@ -642,13 +642,12 @@ static bool rarch_game_specific_options(char **output) strlcat(game_path, ".opt", PATH_MAX_LENGTH); option_file = config_file_new(game_path); - if(option_file) + if (option_file) { - RARCH_LOG("Per-game options: game-specific core options found at %s\n", game_path); + RARCH_LOG("Per-Game Options: game-specific core options found at %s\n", game_path); *output = game_path; return true; } - config_file_free(option_file); return false; } diff --git a/libretro-common/file/file_path.c b/libretro-common/file/file_path.c index c6d5f3cf34..1a232e2204 100644 --- a/libretro-common/file/file_path.c +++ b/libretro-common/file/file_path.c @@ -572,7 +572,7 @@ void fill_pathname_resolve_relative(char *out_path, void fill_pathname_join(char *out_path, const char *dir, const char *path, size_t size) { - if (out_path!=dir) + if (out_path != dir) retro_assert(strlcpy(out_path, dir, size) < size); if (*out_path)