diff options
author | mvglasow <michael -at- vonglasow.com> | 2020-08-11 19:32:32 +0200 |
---|---|---|
committer | mvglasow <michael -at- vonglasow.com> | 2020-08-11 19:32:32 +0200 |
commit | 0a17ef1898eb7cd865350c9986661cc194237a6c (patch) | |
tree | 0d6a5b5cb5d838ba83d2e5cd7a0134bb1c422c17 /navit/util.c | |
parent | 131acbffd9025c8579e12b2a46d9467a15ee1e0b (diff) | |
download | navit-0a17ef1898eb7cd865350c9986661cc194237a6c.tar.gz |
Refactor:core:Add documentation
Signed-off-by: mvglasow <michael -at- vonglasow.com>
Diffstat (limited to 'navit/util.c')
-rw-r--r-- | navit/util.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/navit/util.c b/navit/util.c index cf4412938..0dfdab20e 100644 --- a/navit/util.c +++ b/navit/util.c @@ -479,6 +479,19 @@ GList *g_hash_to_list_keys(GHashTable *h) { return ret; } +/** + * @brief Appends a formatted string and appends it to an existing one. + * + * Usage is similar to the familiar C functions that take a format string and a variable argument list. + * + * Return value is a concatenation of `buffer` (unless it is NULL) and `fmt`, with the remaining arguments + * inserted into `fmt`. + * + * @param buffer An existing string, can be null and will be freed by this function + * @param fmt A format string (will not be altered) + * + * @return A newly allocated string, see description. The caller is responsible for freeing the returned string. + */ gchar *g_strconcat_printf(gchar *buffer, gchar *fmt, ...) { gchar *str,*ret; va_list ap; |