From d468cfbb7977568553aa8e9ed90cc03eda208dd0 Mon Sep 17 00:00:00 2001 From: Greg Hudson Date: Fri, 10 Apr 2009 19:50:55 +0000 Subject: [PATCH] Check return value of krb5int_copy_data_contents in preauth2.c's pa_salt. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@22189 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/krb5/krb/preauth2.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/lib/krb5/krb/preauth2.c b/src/lib/krb5/krb/preauth2.c index 73f4e79b6..ed4708e1b 100644 --- a/src/lib/krb5/krb/preauth2.c +++ b/src/lib/krb5/krb/preauth2.c @@ -634,10 +634,13 @@ krb5_error_code pa_salt(krb5_context context, krb5_gic_get_as_key_fct gak_fct, void *gak_data) { krb5_data tmp; + krb5_error_code retval; tmp = padata2data(*in_padata); krb5_free_data_contents(context, salt); - krb5int_copy_data_contents(context, &tmp, salt); + retval = krb5int_copy_data_contents(context, &tmp, salt); + if (retval) + return retval; if (in_padata->pa_type == KRB5_PADATA_AFS3_SALT) salt->length = SALT_TYPE_AFS_LENGTH; -- 2.26.2