Danilo says we can get rid of the DLLIMP stuff now
[krb5.git] / src / lib / gssapi / krb5 / set_ccache.c
1 #include "gssapiP_krb5.h"
2
3 OM_uint32 KRB5_CALLCONV 
4 gss_krb5_ccache_name(minor_status, name, out_name)
5         OM_uint32 *minor_status;
6         const char *name;
7         const char **out_name;
8 {
9         krb5_context context;
10         krb5_error_code retval;
11         OM_uint32 foo_stat;
12
13         if (GSS_ERROR(kg_get_context(minor_status, &context)))
14                 return (GSS_S_FAILURE);
15
16         if (out_name)
17                 *out_name = krb5_cc_default_name(context);
18
19         retval = krb5_cc_set_default_name(context, name);
20         if (retval) {
21                 *minor_status = retval;
22                 return GSS_S_FAILURE;
23         }
24         kg_release_defcred(&foo_stat);
25         return GSS_S_COMPLETE;
26 }
27                 
28
29         
30