From 71edae59553c02315499ca05fbfd0e90dc8c4e70 Mon Sep 17 00:00:00 2001 From: libretroadmin Date: Thu, 25 Jan 2024 16:04:11 +0100 Subject: [PATCH] Fix unused function warning --- tasks/task_patch.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/tasks/task_patch.c b/tasks/task_patch.c index 35ae38e6ed..8eb30f5c56 100644 --- a/tasks/task_patch.c +++ b/tasks/task_patch.c @@ -616,12 +616,12 @@ static enum patch_error ips_apply_patch( return PATCH_PATCH_INVALID; } +#if defined(HAVE_PATCH) && defined(HAVE_XDELTA) static enum patch_error xdelta_apply_patch( const uint8_t *patchdata, uint64_t patchlen, const uint8_t *sourcedata, uint64_t sourcelength, uint8_t **targetdata, uint64_t *targetlength) { -#if defined(HAVE_PATCH) && defined(HAVE_XDELTA) int ret; enum patch_error error_patch = PATCH_SUCCESS; xd3_stream stream; @@ -710,10 +710,8 @@ cleanup_stream: xd3_close_stream(&stream); xd3_free_stream(&stream); return error_patch; -#else /* HAVE_PATCH is defined and HAVE_XDELTA is defined */ - return PATCH_PATCH_UNSUPPORTED; -#endif } +#endif static bool apply_patch_content(uint8_t **buf, ssize_t *size, const char *patch_desc, const char *patch_path,