diff --git a/lib/krb5/fcache.c b/lib/krb5/fcache.c index 1c32389fa..c7a2c0382 100644 --- a/lib/krb5/fcache.c +++ b/lib/krb5/fcache.c @@ -1306,6 +1306,7 @@ is_default_collection(krb5_context context, const char *name, { krb5_error_code ret; const char *def_loc[2] = { KRB5_DEFAULT_CCNAME_FILE, NULL }; + const char *const def_loc[2] = { KRB5_DEFAULT_CCNAME_FILE, NULL }; const char *sep; size_t namelen; size_t i; @@ -1385,7 +1386,8 @@ fcc_get_cache_first(krb5_context context, krb5_cc_cursor *cursor) * locations. */ if ((ret = is_default_collection(context, def_ccname, - (const char **)def_locs, + /* XXX strict aliasing violation */ + (const char * const *)def_locs, &is_def_coll))) goto out;