aboutsummaryrefslogtreecommitdiff
path: root/common.c
diff options
context:
space:
mode:
authorPřemysl Janouch <p.janouch@gmail.com>2018-01-08 22:15:29 +0100
committerPřemysl Janouch <p.janouch@gmail.com>2018-01-08 22:19:28 +0100
commit4586b0e1e475f73ed7ac025b0c3a546f76fb3230 (patch)
treea7fe22a08e6dca470f433147edec56b2a0ea0efe /common.c
parentb4507b56afcdcdcc443b5a838aaadde7e62ed520 (diff)
downloadxK-4586b0e1e475f73ed7ac025b0c3a546f76fb3230.tar.gz
xK-4586b0e1e475f73ed7ac025b0c3a546f76fb3230.tar.xz
xK-4586b0e1e475f73ed7ac025b0c3a546f76fb3230.zip
degesch: introduce cstr_set()
Diffstat (limited to 'common.c')
-rw-r--r--common.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/common.c b/common.c
index bd5184c..a735aeb 100644
--- a/common.c
+++ b/common.c
@@ -51,6 +51,13 @@ init_openssl (void)
// --- To be moved to liberty --------------------------------------------------
+static void
+cstr_set (char **s, char *new)
+{
+ free (*s);
+ *s = new;
+}
+
static ssize_t
strv_find (const struct strv *v, const char *s)
{