1 ///////////////////////////////////////////////////////////////////////////////
4 /// \brief Checks filename suffix and creates the destination filename
6 // Author: Lasse Collin
8 // This file has been put into the public domain.
9 // You can do whatever you want with this file.
11 ///////////////////////////////////////////////////////////////////////////////
13 /// \brief Get the name of the destination file
15 /// Depending on the global variable opt_mode, this tries to find a matching
16 /// counterpart for src_name. If the name can be constructed, it is allocated
17 /// and returned (caller must free it). On error, a message is printed and
19 extern char *suffix_get_dest_name(const char *src_name);
22 /// \brief Set a custom filename suffix
24 /// This function calls xstrdup() for the given suffix, thus the caller
25 /// doesn't need to keep the memory allocated. There can be only one custom
26 /// suffix, thus if this is called multiple times, the old suffixes are freed
28 extern void suffix_set(const char *suffix);