From: Scott McGuire Date: Mon, 7 Feb 2000 21:36:32 +0000 (+0000) Subject: changepw.c (krb5_locate_kpasswd): fixed memory trashing caused by incorrect pointer... X-Git-Tag: krb5-1.2-beta1~101 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=7b8ae297d788b9477917a274085a2af3ddee62b2;p=krb5.git changepw.c (krb5_locate_kpasswd): fixed memory trashing caused by incorrect pointer arithmetic when assigning DEFAULT_KPASSWD_PORT in DNS code git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12019 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/lib/krb5/os/ChangeLog b/src/lib/krb5/os/ChangeLog index 32245f8c5..b50565daf 100644 --- a/src/lib/krb5/os/ChangeLog +++ b/src/lib/krb5/os/ChangeLog @@ -1,3 +1,9 @@ +2000-02-07 Scott McGuire + + * changepw.c (krb5_locate_kpasswd): fixed memory trashing + caused by incorrect pointer arithmetic when assigning + DEFAULT_KPASSWD_PORT in DNS code also. + 2000-02-04 Scott McGuire * changepw.c (krb5_locate_kpasswd): fixed memory trashing diff --git a/src/lib/krb5/os/changepw.c b/src/lib/krb5/os/changepw.c index f6bf3a920..6ed95bce7 100644 --- a/src/lib/krb5/os/changepw.c +++ b/src/lib/krb5/os/changepw.c @@ -103,7 +103,7 @@ krb5_locate_kpasswd(context, realm, addr_pp, naddrs, master_index, nmasters) /* success with admin_server but now we need to change the port */ /* number to use DEFAULT_KPASSWD_PORT. */ for ( i=0;i<*naddrs;i++ ) { - struct sockaddr_in *sin = (struct sockaddr_in *) &(*addr_pp)[i]; + struct sockaddr_in *sin = (struct sockaddr_in *) addr_pp[i]; sin->sin_port = htons(DEFAULT_KPASSWD_PORT); } }