svn rev #24326: trunk/src/clients/kinit/
ghudson@MIT.EDU
ghudson at MIT.EDU
Fri Sep 17 11:52:23 EDT 2010
http://src.mit.edu/fisheye/changelog/krb5/?cs=24326
Commit By: ghudson
Log Message:
In kinit_kdb_init(), ensure that we don't return an error with the
old, freed value of *pcontext still there--that would result in a
double free.
Changed Files:
U trunk/src/clients/kinit/kinit_kdb.c
Modified: trunk/src/clients/kinit/kinit_kdb.c
===================================================================
--- trunk/src/clients/kinit/kinit_kdb.c 2010-09-16 19:57:53 UTC (rev 24325)
+++ trunk/src/clients/kinit/kinit_kdb.c 2010-09-17 15:52:23 UTC (rev 24326)
@@ -52,8 +52,10 @@
kadm5_config_params config;
krb5_error_code retval = 0;
- if (*pcontext)
+ if (*pcontext) {
krb5_free_context(*pcontext);
+ *pcontext = NULL;
+ }
memset(&config, 0, sizeof config);
retval = kadm5_init_krb5_context(pcontext);
if (retval)
More information about the cvs-krb5
mailing list