From 56633d2ffc21ceedbdbfba94960f84fa0442b5fb Mon Sep 17 00:00:00 2001 From: John Kohl Date: Fri, 31 Aug 1990 14:16:02 +0000 Subject: [PATCH] need to update cursor git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@1068 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/krb5/keytab/file/ktf_next.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/lib/krb5/keytab/file/ktf_next.c b/src/lib/krb5/keytab/file/ktf_next.c index 9ec84876a..2d9e05ceb 100644 --- a/src/lib/krb5/keytab/file/ktf_next.c +++ b/src/lib/krb5/keytab/file/ktf_next.c @@ -25,16 +25,17 @@ krb5_error_code krb5_ktfile_get_next(id, entry, cursor) krb5_keytab id; krb5_keytab_entry *entry; -krb5_kt_cursor cursor; +krb5_kt_cursor *cursor; { - long fileoff = *(long *)cursor; + long *fileoff = (long *)cursor; krb5_keytab_entry *cur_entry; krb5_error_code kerror; - if (fseek(KTFILEP(id), fileoff, 0) == -1) + if (fseek(KTFILEP(id), *fileoff, 0) == -1) return KRB5_KT_END; if (kerror = krb5_ktfileint_read_entry(id, &cur_entry)) return kerror; + *fileoff = ftell(KTFILEP(id)); *entry = *cur_entry; xfree(cur_entry); return 0; -- 2.26.2