]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Remove archive_utility_string_sort with 4.0.0 2650/head
authorTobias Stoeckmann <tobias@stoeckmann.org>
Fri, 30 May 2025 15:41:26 +0000 (17:41 +0200)
committerTobias Stoeckmann <tobias@stoeckmann.org>
Fri, 30 May 2025 15:41:26 +0000 (17:41 +0200)
The archive_utility_string_sort function won't be part of the 4.0.0 API
anymore. No users were found and such a task should be done outside of
the library.

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
libarchive/archive.h
libarchive/archive_util.c

index 02aa1b15759488c7304d707ce52f8ddbcac9f4b3..dceb5558f5dad1ed340ee1dc1e5020c79af70c53 100644 (file)
@@ -1250,8 +1250,10 @@ __LA_DECL int    archive_match_include_gname_w(struct archive *,
                    const wchar_t *);
 
 /* Utility functions */
+#if ARCHIVE_VERSION_NUMBER < 4000000
 /* Convenience function to sort a NULL terminated list of strings */
 __LA_DECL int archive_utility_string_sort(char **);
+#endif
 
 #ifdef __cplusplus
 }
index 97185c0043c1c3b2846a0795b973f85b28ca1fe7..900abd0c3c62027c8ee1a71962a7c5313d29e752 100644 (file)
@@ -77,7 +77,9 @@
 #define O_CLOEXEC      0
 #endif
 
+#if ARCHIVE_VERSION_NUMBER < 4000000
 static int __LA_LIBC_CC archive_utility_string_sort_helper(const void *, const void *);
+#endif
 
 /* Generic initialization of 'struct archive' objects. */
 int
@@ -629,6 +631,7 @@ __archive_ensure_cloexec_flag(int fd)
 #endif
 }
 
+#if ARCHIVE_VERSION_NUMBER < 4000000
 /*
  * Utility functions to sort a group of strings using quicksort.
  */
@@ -652,3 +655,4 @@ archive_utility_string_sort(char **strings)
              archive_utility_string_sort_helper);
        return (ARCHIVE_OK);
 }
+#endif