Fix printf argument type mismatches related to pw_max_fail in
authorGreg Hudson <ghudson@mit.edu>
Mon, 26 Oct 2009 15:10:00 +0000 (15:10 +0000)
committerGreg Hudson <ghudson@mit.edu>
Mon, 26 Oct 2009 15:10:00 +0000 (15:10 +0000)
kadmin.c.

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

src/kadmin/cli/kadmin.c

index 51746def446f2f8714be10a28381f7a21a16eeea..22a67ab156a9b3c828fb5bd0f1fe2ffd880bca5c 100644 (file)
@@ -1640,18 +1640,19 @@ kadmin_getpol(int argc, char *argv[])
                policy.pw_min_classes);
         printf("Number of old keys kept: %ld\n", policy.pw_history_num);
         printf("Reference count: %ld\n", policy.policy_refcnt);
-        printf("Maximum password failures before lockout: %ld\n",
-                policy.pw_max_fail);
+        printf("Maximum password failures before lockout: %lu\n",
+               (unsigned long)policy.pw_max_fail);
         printf("Password failure count reset interval: %ld\n",
                 (long)policy.pw_failcnt_interval);
         printf("Password lockout duration: %ld\n",
                 (long)policy.pw_lockout_duration);
     } else {
-        printf("\"%s\"\t%ld\t%ld\t%ld\t%ld\t%ld\t%ld\t%ld\t%ld\t%ld\n",
+        printf("\"%s\"\t%ld\t%ld\t%ld\t%ld\t%ld\t%ld\t%lu\t%ld\t%ld\n",
                policy.policy, policy.pw_max_life, policy.pw_min_life,
                policy.pw_min_length, policy.pw_min_classes,
                policy.pw_history_num, policy.policy_refcnt,
-               policy.pw_max_fail, (long)policy.pw_failcnt_interval,
+               (unsigned long)policy.pw_max_fail,
+               (long)policy.pw_failcnt_interval,
                (long)policy.pw_lockout_duration);
     }
     kadm5_free_policy_ent(handle, &policy);