From 7f602784de4fd378120e8ebfe6d830862b9cae03 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 2 Apr 2013 20:38:16 +0200 Subject: util: rename parse_usec() to parse_sec() sinds the default unit is seconds Internally we store all time values in usec_t, however parse_usec() actually was used mostly to parse values in seconds (unless explicit units were specified to define a different unit). Hence, be clear about this and name the function about what we pass into it, not what we get out of it. --- src/shared/conf-parser.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/shared/conf-parser.c') diff --git a/src/shared/conf-parser.c b/src/shared/conf-parser.c index c2cf5a6a19..a87df382ea 100644 --- a/src/shared/conf-parser.c +++ b/src/shared/conf-parser.c @@ -792,7 +792,7 @@ int config_parse_path_strv( return 0; } -int config_parse_usec( +int config_parse_sec( const char *filename, unsigned line, const char *section, @@ -809,7 +809,7 @@ int config_parse_usec( assert(rvalue); assert(data); - if (parse_usec(rvalue, usec) < 0) { + if (parse_sec(rvalue, usec) < 0) { log_error("[%s:%u] Failed to parse time value, ignoring: %s", filename, line, rvalue); return 0; } -- cgit v1.2.3-54-g00ecf