diff options
author | Tom Yu <tlyu@mit.edu> | 2010-12-01 02:16:37 +0000 |
---|---|---|
committer | Tom Yu <tlyu@mit.edu> | 2010-12-01 02:16:37 +0000 |
commit | 72aea6d91dfd1d522d109ebb41dac3e0621bdb5d (patch) | |
tree | 3b70189912969a1e45d61f7c739d3b4356b00e69 | |
parent | 67e404e70a2a6c8492c62c365b25e0e253e0543e (diff) | |
download | krb5-72aea6d91dfd1d522d109ebb41dac3e0621bdb5d.zip krb5-72aea6d91dfd1d522d109ebb41dac3e0621bdb5d.tar.gz krb5-72aea6d91dfd1d522d109ebb41dac3e0621bdb5d.tar.bz2 |
pull up r24529, r24532 from trunk
------------------------------------------------------------------------
r24532 | tlyu | 2010-11-23 18:51:50 -0500 (Tue, 23 Nov 2010) | 6 lines
ticket: 6825
Update krb5_gic_opt_private and related code to reflect the change of
krb5_expire_callback_func from a function typedef to a function
pointer typedef. This was causing segfaults.
------------------------------------------------------------------------
r24529 | ghudson | 2010-11-22 23:50:40 -0500 (Mon, 22 Nov 2010) | 9 lines
ticket: 6825
subject: Add missing KRB5_CALLCONV in callback declaration
target_version: 1.9
tags: pullup
krb5_get_init_creds_opt_set_expire_callback was correctly tagged with
KRB5_CALLCONV but the corresponding callback type was not. Add that
in.
ticket: 6825
version_fixed: 1.9
status: resolved
git-svn-id: svn://anonsvn.mit.edu/krb5/branches/krb5-1-9@24546 dc483132-0cff-0310-8789-dd5450dbe970
-rw-r--r-- | src/include/k5-int.h | 2 | ||||
-rw-r--r-- | src/include/krb5/krb5.hin | 8 | ||||
-rw-r--r-- | src/lib/krb5/krb/gic_pwd.c | 2 |
3 files changed, 6 insertions, 6 deletions
diff --git a/src/include/k5-int.h b/src/include/k5-int.h index ca14586..229d2d2 100644 --- a/src/include/k5-int.h +++ b/src/include/k5-int.h @@ -1150,7 +1150,7 @@ typedef struct _krb5_gic_opt_private { char * fast_ccache_name; krb5_ccache out_ccache; krb5_flags fast_flags; - krb5_expire_callback_func *expire_cb; + krb5_expire_callback_func expire_cb; void *expire_data; } krb5_gic_opt_private; diff --git a/src/include/krb5/krb5.hin b/src/include/krb5/krb5.hin index e04cf3b..51d7d72 100644 --- a/src/include/krb5/krb5.hin +++ b/src/include/krb5/krb5.hin @@ -2381,10 +2381,10 @@ krb5_get_init_creds_opt_get_fast_flags(krb5_context context, #define KRB5_FAST_REQUIRED 1l<<0 /*!< Require KDC to support FAST*/ typedef void -krb5_expire_callback_func(krb5_context context, void *data, - krb5_timestamp password_expiration, - krb5_timestamp account_expiration, - krb5_boolean is_last_req); +(KRB5_CALLCONV *krb5_expire_callback_func)(krb5_context context, void *data, + krb5_timestamp password_expiration, + krb5_timestamp account_expiration, + krb5_boolean is_last_req); /** * Set a callback to receive password and account expiration times. diff --git a/src/lib/krb5/krb/gic_pwd.c b/src/lib/krb5/krb/gic_pwd.c index 1e0b741..1fdc814 100644 --- a/src/lib/krb5/krb/gic_pwd.c +++ b/src/lib/krb5/krb/gic_pwd.c @@ -159,7 +159,7 @@ warn_pw_expiry(krb5_context context, krb5_get_init_creds_opt *options, ret = krb5int_gic_opt_to_opte(context, options, &opte, 0, ""); if (ret == 0 && opte->opt_private->expire_cb != NULL) { - krb5_expire_callback_func *cb = opte->opt_private->expire_cb; + krb5_expire_callback_func cb = opte->opt_private->expire_cb; void *cb_data = opte->opt_private->expire_data; /* Invoke the expire callback and don't send prompter warnings. */ |