From b5ea9e240ef4851eb73c86926bbc9b31fc789e3d Mon Sep 17 00:00:00 2001 From: olavmrk Date: Fri, 25 Apr 2014 09:11:35 +0000 Subject: Silence warning The -Wunused-but-set-variable option will cause a warning that idp_public_key_file is set but never used when HAVE_lasso_server_load_metadata is defined. Signed-off-by: Simo Sorce git-svn-id: https://modmellon.googlecode.com/svn/trunk@225 a716ebb1-153a-0410-b759-cfb97c6a1b53 --- auth_mellon_handler.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/auth_mellon_handler.c b/auth_mellon_handler.c index f93ba6e..1d42fd7 100644 --- a/auth_mellon_handler.c +++ b/auth_mellon_handler.c @@ -218,13 +218,16 @@ static char *am_generate_metadata(apr_pool_t *p, request_rec *r) */ static guint am_server_add_providers(am_dir_cfg_rec *cfg, request_rec *r) { - const char *idp_public_key_file; apr_size_t index; +#ifndef HAVE_lasso_server_load_metadata + const char *idp_public_key_file; + if (cfg->idp_metadata->nelts == 1) idp_public_key_file = cfg->idp_public_key_file; else idp_public_key_file = NULL; +#endif /* ! HAVE_lasso_server_load_metadata */ for (index = 0; index < cfg->idp_metadata->nelts; index++) { const am_metadata_t *idp_metadata; -- cgit