From 8fb494435889dcb9e1c09b8c7220e47bab717bf9 Mon Sep 17 00:00:00 2001 From: Zbigniew Jędrzejewski-Szmek Date: Mon, 27 Jul 2015 22:15:26 -0400 Subject: hostname-util: add relax parameter to hostname_is_valid Tests are modified to check behaviour with relax and without relax. New tests are added for hostname_cleanup(). Tests are moved a new file (test-hostname-util) because there's now a bunch of them. New parameter is not used anywhere, except in tests, so there should be no observable change. --- src/locale/localed.c | 5 ----- 1 file changed, 5 deletions(-) (limited to 'src/locale') diff --git a/src/locale/localed.c b/src/locale/localed.c index 88756542fd..3b511bfaf4 100644 --- a/src/locale/localed.c +++ b/src/locale/localed.c @@ -99,11 +99,6 @@ static const char* nonempty(const char *s) { return isempty(s) ? NULL : s; } -static void free_and_replace(char **s, char *v) { - free(*s); - *s = v; -} - static bool startswith_comma(const char *s, const char *prefix) { const char *t; -- cgit v1.2.3-54-g00ecf