Declare get_date() used from kadmin cli code.
authorKen Raeburn <raeburn@mit.edu>
Thu, 31 Aug 2006 22:08:45 +0000 (22:08 +0000)
committerKen Raeburn <raeburn@mit.edu>
Thu, 31 Aug 2006 22:08:45 +0000 (22:08 +0000)
In calls, delete the second argument that get_date doesn't take.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@18556 dc483132-0cff-0310-8789-dd5450dbe970

src/plugins/kdb/ldap/ldap_util/kdb5_ldap_policy.c
src/plugins/kdb/ldap/ldap_util/kdb5_ldap_realm.c

index 7bcac41a61105ab35953c50d86eb93eb213b272a..6e6de49821bef2a351d56f82448a72300ee606ae 100644 (file)
 #include "kdb5_ldap_util.h"
 #include "kdb5_ldap_list.h"
 #include "ldap_tkt_policy.h"
+extern time_t get_date(char *); /* kadmin/cli/getdate.o */
 
 static void print_policy_params(krb5_ldap_policy_params *policyparams, int mask);
 static char *strdur(time_t duration);
 
-/* get_date() function used from src/kadmin/ldap_util/getdate.c */
-
 extern char *yes;
 
-
 /*
  * This function will create a ticket policy object with the
  * specified attributes.
@@ -88,7 +86,7 @@ kdb5_ldap_create_policy(argc, argv)
            if (++i > argc - 1)
                goto err_usage;
 
-           date = get_date(argv[i], NULL);
+           date = get_date(argv[i]);
            if (date == (time_t)(-1)) {
                retval = EINVAL;
                com_err (me, retval, "while providing time specification");
@@ -102,7 +100,7 @@ kdb5_ldap_create_policy(argc, argv)
            if (++i > argc - 1)
                goto err_usage;
 
-           date = get_date(argv[i], NULL);
+           date = get_date(argv[i]);
            if (date == (time_t)(-1)) {
                retval = EINVAL;
                com_err (me, retval, "while providing time specification");
@@ -454,7 +452,7 @@ kdb5_ldap_modify_policy(argc, argv)
            if (++i > argc - 1)
                goto err_usage;
 
-           date = get_date(argv[i], NULL);
+           date = get_date(argv[i]);
            if (date == (time_t)(-1)) {
                retval = EINVAL;
                com_err (me, retval, "while providing time specification");
@@ -468,7 +466,7 @@ kdb5_ldap_modify_policy(argc, argv)
            if (++i > argc - 1)
                goto err_usage;
 
-           date = get_date(argv[i], NULL);
+           date = get_date(argv[i]);
            if (date == (time_t)(-1)) {
                retval = EINVAL;
                com_err (me, retval, "while providing time specification");
index cbfb5b0dd02eb21d2af3b026c15c1b5729cc8954..ea98647da9fbc0ad9aa67c52e762ba1bd7684b16 100644 (file)
@@ -87,6 +87,7 @@
 #include "kdb5_ldap_util.h"
 #include "kdb5_ldap_list.h"
 #include <ldap_principal.h>
+extern time_t get_date(char *); /* kadmin/cli/getdate.o */
 
 char *yes = "yes\n"; /* \n to compare against result of fgets */
 krb5_key_salt_tuple def_kslist = {ENCTYPE_DES_CBC_CRC, KRB5_KDB_SALTTYPE_NORMAL};
@@ -148,7 +149,7 @@ static int get_ticket_policy(rparams,i,argv,argc)
     if (!strcmp(argv[*i], "-maxtktlife")) {
        if (++(*i) > argc-1)
            goto err_usage;
-       date = get_date(argv[*i], NULL);
+       date = get_date(argv[*i]);
        if (date == (time_t)(-1)) {
            retval = EINVAL;
            com_err (me, retval, "while providing time specification");
@@ -163,7 +164,7 @@ static int get_ticket_policy(rparams,i,argv,argc)
        if (++(*i) > argc-1)
            goto err_usage;
 
-       date = get_date(argv[*i], NULL);
+       date = get_date(argv[*i]);
        if (date == (time_t)(-1)) {
            retval = EINVAL;
            com_err (me, retval, "while providing time specification");