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