Update for 1.12's removal of krb5_xfree()
This commit is contained in:
parent
f619caa9c9
commit
447ee6c9e6
@ -113,7 +113,7 @@ diff -up /dev/null krb5-1.7/src/lib/krb5/keytab/kt_any.c
|
||||
+ if ((data = (krb5_ktany_data *)malloc(sizeof(krb5_ktany_data))) == NULL)
|
||||
+ return(ENOMEM);
|
||||
+ if ((data->name = (char *)malloc(strlen(name) + 1)) == NULL) {
|
||||
+ krb5_xfree(data);
|
||||
+ free(data);
|
||||
+ return(ENOMEM);
|
||||
+ }
|
||||
+ strcpy(data->name, name);
|
||||
@ -124,8 +124,8 @@ diff -up /dev/null krb5-1.7/src/lib/krb5/keytab/kt_any.c
|
||||
+ data->nchoices++;
|
||||
+ if ((data->choices = (krb5_keytab *)
|
||||
+ malloc(data->nchoices * sizeof(krb5_keytab))) == NULL) {
|
||||
+ krb5_xfree(data->name);
|
||||
+ krb5_xfree(data);
|
||||
+ free(data->name);
|
||||
+ free(data);
|
||||
+ return(ENOMEM);
|
||||
+ }
|
||||
+
|
||||
@ -142,7 +142,7 @@ diff -up /dev/null krb5-1.7/src/lib/krb5/keytab/kt_any.c
|
||||
+
|
||||
+ /* Try resolving the choice name. */
|
||||
+ kerror = krb5_kt_resolve(context, copy, &data->choices[i]);
|
||||
+ krb5_xfree(copy);
|
||||
+ free(copy);
|
||||
+ if (kerror) {
|
||||
+ cleanup(context, data, i);
|
||||
+ return(kerror);
|
||||
@ -190,7 +190,7 @@ diff -up /dev/null krb5-1.7/src/lib/krb5/keytab/kt_any.c
|
||||
+
|
||||
+ cleanup(context, data, data->nchoices);
|
||||
+ id->ops = 0;
|
||||
+ krb5_xfree(id);
|
||||
+ free(id);
|
||||
+ return(0);
|
||||
+}
|
||||
+
|
||||
@ -236,14 +236,14 @@ diff -up /dev/null krb5-1.7/src/lib/krb5/keytab/kt_any.c
|
||||
+ &cdata->cursor)) == 0)
|
||||
+ break;
|
||||
+ else if (kerror != ENOENT) {
|
||||
+ krb5_xfree(cdata);
|
||||
+ free(cdata);
|
||||
+ return(kerror);
|
||||
+ }
|
||||
+ }
|
||||
+
|
||||
+ if (i == data->nchoices) {
|
||||
+ /* Everyone returned ENOENT, so no go. */
|
||||
+ krb5_xfree(cdata);
|
||||
+ free(cdata);
|
||||
+ return(kerror);
|
||||
+ }
|
||||
+
|
||||
@ -280,7 +280,7 @@ diff -up /dev/null krb5-1.7/src/lib/krb5/keytab/kt_any.c
|
||||
+
|
||||
+ choice_id = data->choices[cdata->which];
|
||||
+ kerror = krb5_kt_end_seq_get(context, choice_id, &cdata->cursor);
|
||||
+ krb5_xfree(cdata);
|
||||
+ free(cdata);
|
||||
+ return(kerror);
|
||||
+}
|
||||
+
|
||||
@ -292,11 +292,11 @@ diff -up /dev/null krb5-1.7/src/lib/krb5/keytab/kt_any.c
|
||||
+{
|
||||
+ int i;
|
||||
+
|
||||
+ krb5_xfree(data->name);
|
||||
+ free(data->name);
|
||||
+ for (i = 0; i < nchoices; i++)
|
||||
+ krb5_kt_close(context, data->choices[i]);
|
||||
+ krb5_xfree(data->choices);
|
||||
+ krb5_xfree(data);
|
||||
+ free(data->choices);
|
||||
+ free(data);
|
||||
+}
|
||||
diff -up krb5-1.7/src/lib/krb5/keytab/ktbase.c krb5-1.7/src/lib/krb5/keytab/ktbase.c
|
||||
--- krb5-1.7/src/lib/krb5/keytab/ktbase.c 2009-02-18 13:18:56.000000000 -0500
|
@ -75,7 +75,7 @@ Source100: nss_wrapper-0.0-20130719153839Z.git6cb59864.bz2
|
||||
Source101: noport.c
|
||||
|
||||
Patch6: krb5-1.12-ksu-path.patch
|
||||
Patch12: krb5-1.7-ktany.patch
|
||||
Patch12: krb5-1.12-ktany.patch
|
||||
Patch16: krb5-1.12-buildconf.patch
|
||||
Patch23: krb5-1.3.1-dns.patch
|
||||
Patch29: krb5-1.10-kprop-mktemp.patch
|
||||
|
Loading…
Reference in New Issue
Block a user