* copy_addrs.c (krb5_copy_addr): make non-static so we can use it
in mk_cred.
* mk_cred.c (krb5_mk_ncred_basic): copy local_addr and remote_addr
instead of just aliasing them, so we can safely free them ourselves.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7653
dc483132-0cff-0310-8789-
dd5450dbe970
* Makefile.in: Rework to be consistant with configure defines so
that configure can specify other needed libraries.
+Sun Mar 17 02:10:19 1996 Mark W. Eichin <eichin@cygnus.com>
+
+ * copy_addrs.c (krb5_copy_addr): make non-static so we can use it
+ in mk_cred.
+ * mk_cred.c (krb5_mk_ncred_basic): copy local_addr and remote_addr
+ instead of just aliasing them, so we can safely free them ourselves.
+
Fri Mar 15 14:29:00 1996 Richard Basch <basch@lehman.com>
* in_tkt_ktb.c: Close the keytab if we opened it, not if the
#include "k5-int.h"
-static krb5_error_code
+krb5_error_code
krb5_copy_addr(context, inad, outad)
krb5_context context;
const krb5_address *inad;
credenc.magic = KV5M_CRED_ENC_PART;
- credenc.s_address = local_addr;
- credenc.r_address = remote_addr;
+ credenc.s_address = 0;
+ credenc.r_address = 0;
+ if (local_addr) krb5_copy_addr(context, local_addr, &credenc.s_address);
+ if (remote_addr) krb5_copy_addr(context, remote_addr, &credenc.r_address);
+
credenc.nonce = replaydata->seq;
credenc.usec = replaydata->usec;
credenc.timestamp = replaydata->timestamp;