aboutsummaryrefslogtreecommitdiff
path: root/src/xz/suffix.h
diff options
context:
space:
mode:
authorJia Tan <jiat0218@gmail.com>2023-01-07 21:55:06 +0800
committerJia Tan <jiat0218@gmail.com>2023-02-03 21:38:26 +0800
commit99575947a58a60416c570eb78038d18a1ea4cef4 (patch)
tree9064bc92eb57e358ac30ccbdacf4eb8247dfc1ed /src/xz/suffix.h
parentliblzma: Set documentation on all reserved fields to private. (diff)
downloadxz-99575947a58a60416c570eb78038d18a1ea4cef4.tar.xz
xz: Refactor duplicated check for custom suffix when using --format=raw
Diffstat (limited to '')
-rw-r--r--src/xz/suffix.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/xz/suffix.h b/src/xz/suffix.h
index 5537d732..135e9056 100644
--- a/src/xz/suffix.h
+++ b/src/xz/suffix.h
@@ -26,3 +26,11 @@ extern char *suffix_get_dest_name(const char *src_name);
/// suffix, thus if this is called multiple times, the old suffixes are freed
/// and forgotten.
extern void suffix_set(const char *suffix);
+
+
+/// \brief Check if a custom suffix has been set
+///
+/// Returns true if the internal tracking of the suffix string has been set
+/// and false if the string has not been set. This will keep the suffix
+/// string encapsulated instead of extern-ing the variable.
+extern bool suffix_is_set(void);