]> git.ipfire.org Git - thirdparty/shadow.git/commitdiff
lib/: get_date(): Remove unused parameter
authorAlejandro Colomar <alx@kernel.org>
Tue, 18 Feb 2025 14:19:38 +0000 (15:19 +0100)
committerIker Pedrosa <ikerpedrosam@gmail.com>
Mon, 2 Jun 2025 07:59:51 +0000 (09:59 +0200)
And rename the remaining parameter.

Signed-off-by: Alejandro Colomar <alx@kernel.org>
lib/getdate.c
lib/getdate.h
lib/strtoday.c

index 7479875e8060c54cd410afe0009fda043943b45c..f9a3f837abf516be85653e9ca8f48d87fc70bbf7 100644 (file)
@@ -31,11 +31,11 @@ static int parse_date(const char *s);
 
 
 time_t
-get_date(const char *p, const time_t *now)
+get_date(const char *s)
 {
        struct tm  tm;
 
-       if (parse_date(p) == -1)
+       if (parse_date(s) == -1)
                return -1;
 
        tm.tm_year = yyYear - TM_YEAR_ORIGIN;
index eae56f647f70bb0849a0801da0b064036b39a464..7348559214e1a4366df5188ead6998f25a974511 100644 (file)
@@ -12,5 +12,5 @@
 #include <config.h>
 #include "defines.h"
 
-time_t get_date (const char *p, /*@null@*/const time_t *now);
+time_t get_date(const char *s);
 #endif
index 3d9410181f22ac9077cf9f160437a2f0645a256d..c0b159337b3ecd1c57793cf6e7828237f215aea1 100644 (file)
@@ -49,7 +49,7 @@ strtoday(const char *str)
                return retdate;
        }
 
-       t = get_date(str, NULL);
+       t = get_date(str);
        if ((time_t) - 1 == t) {
                return -2;
        }