From: Ezra Peisach Date: Mon, 7 Jun 2004 19:31:23 +0000 (+0000) Subject: * kpasswd.c (get_name_from_passwd_file): Do not cast return from X-Git-Tag: krb5-1.4-beta1~355 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=2d1b1d0bf3bc459ce6f8775c09b718c0e4afcf49;p=krb5.git * kpasswd.c (get_name_from_passwd_file): Do not cast return from getuid() to int as argument to getpwuid. * ksetpwd.c: Include time.h for time() prototype. (main): Return 0 on success. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@16417 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/clients/kpasswd/ChangeLog b/src/clients/kpasswd/ChangeLog index 000509787..33448e72e 100644 --- a/src/clients/kpasswd/ChangeLog +++ b/src/clients/kpasswd/ChangeLog @@ -1,3 +1,11 @@ +2004-06-07 Ezra Peisach + + * kpasswd.c (get_name_from_passwd_file): Do not cast return from + getuid() to int as argument to getpwuid. + + * ksetpwd.c: Include time.h for time() prototype. + (main): Return 0 on success. + 2004-05-30 Ken Raeburn * ksetpwd.c (verify_creds, get_init_creds_opt_init, diff --git a/src/clients/kpasswd/kpasswd.c b/src/clients/kpasswd/kpasswd.c index b70687435..b2d54f5fe 100644 --- a/src/clients/kpasswd/kpasswd.c +++ b/src/clients/kpasswd/kpasswd.c @@ -21,7 +21,7 @@ void get_name_from_passwd_file(program_name, kcontext, me) { struct passwd *pw; krb5_error_code code; - if ((pw = getpwuid((int) getuid()))) { + if ((pw = getpwuid(getuid()))) { if ((code = krb5_parse_name(kcontext, pw->pw_name, me))) { com_err (program_name, code, "when parsing name %s", pw->pw_name); exit(1); diff --git a/src/clients/kpasswd/ksetpwd.c b/src/clients/kpasswd/ksetpwd.c index aee81015f..148e68651 100644 --- a/src/clients/kpasswd/ksetpwd.c +++ b/src/clients/kpasswd/ksetpwd.c @@ -2,6 +2,7 @@ #include #include #include +#include #define TKTTIMELEFT 60*10 /* ten minutes */ @@ -308,4 +309,5 @@ int main( int argc, char ** argv ) } } } + return(0); }