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-01-21 22:10:51 +0800
commitcc5aa9ab138beeecaee5a1e81197591893ee9ca0 (patch)
treea26ab6b7deb69a6e2a47ea7503191570d34043dc /src/xz/suffix.h
parentliblzma: Set documentation on all reserved fields to private. (diff)
downloadxz-cc5aa9ab138beeecaee5a1e81197591893ee9ca0.tar.xz
xz: Refactor duplicated check for custom suffix when using --format=raw
Diffstat (limited to '')
-rw-r--r--src/xz/suffix.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/xz/suffix.h b/src/xz/suffix.h
index 5537d732..cb36dd61 100644
--- a/src/xz/suffix.h
+++ b/src/xz/suffix.h
@@ -26,3 +26,10 @@ 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);