From d58c525cdc17cca29ff03e3eec354774d988fa84 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Daniel=20Kou=C5=99il?= Date: Fri, 17 Mar 2006 15:24:12 +0000 Subject: [PATCH] Corrected/overcasted types to address some warnings --- org.glite.security.proxyrenewal/src/renewal_core.c | 13 +++++++------ org.glite.security.proxyrenewal/src/renewd.c | 1 + org.glite.security.proxyrenewal/src/renewd_locl.h | 2 +- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/org.glite.security.proxyrenewal/src/renewal_core.c b/org.glite.security.proxyrenewal/src/renewal_core.c index 97309d6..1715f45 100644 --- a/org.glite.security.proxyrenewal/src/renewal_core.c +++ b/org.glite.security.proxyrenewal/src/renewal_core.c @@ -21,7 +21,7 @@ load_proxy(glite_renewal_core_context ctx, const char *cur_file, X509 **cert, EV goto end; } - result = globus_gsi_cred_read_proxy(proxy, cur_file); + result = globus_gsi_cred_read_proxy(proxy, (char *) cur_file); if (result) { fprintf(stderr, "globus_gsi_cred_read_proxy() failed\n"); goto end; @@ -68,13 +68,14 @@ end: } int -get_proxy_base_name(glite_renewal_core_context ctx, char *file, char **name) +get_proxy_base_name(glite_renewal_core_context ctx, const char *file, char **name) { X509 *cert = NULL; EVP_PKEY *key = NULL; STACK_OF(X509) *chain = NULL; X509_NAME *subject = NULL; int ret; + globus_result_t result; ret = load_proxy(ctx, file, &cert, &key, &chain, NULL); if (ret) @@ -85,8 +86,8 @@ get_proxy_base_name(glite_renewal_core_context ctx, char *file, char **name) sk_X509_insert(chain, cert, 0); cert = NULL; - ret = globus_gsi_cert_utils_get_base_name(subject, chain); - if (ret) { + result = globus_gsi_cert_utils_get_base_name(subject, chain); + if (result) { edg_wlpr_Log(ctx, LOG_ERR, "Cannot get subject name from proxy %s", file); ret = EDG_WLPR_ERROR_SSL; /* XXX ??? */ goto end; @@ -119,7 +120,7 @@ glite_renewal_core_renew(glite_renewal_core_context ctx, int tmp_fd; int ret = -1; char *p; - char *server = NULL; + const char *server = NULL; myproxy_socket_attrs_t *socket_attrs; myproxy_request_t *client_request; myproxy_response_t *server_response; @@ -165,7 +166,7 @@ glite_renewal_core_renew(glite_renewal_core_context ctx, socket_attrs->psport = (myproxy_port) ? myproxy_port : MYPROXY_SERVER_PORT; verror_clear(); - ret = myproxy_get_delegation(socket_attrs, client_request, current_proxy, + ret = myproxy_get_delegation(socket_attrs, client_request, (char *) current_proxy, server_response, tmp_proxy); if (ret == 1) { ret = EDG_WLPR_ERROR_MYPROXY; diff --git a/org.glite.security.proxyrenewal/src/renewd.c b/org.glite.security.proxyrenewal/src/renewd.c index 96b89ef..2a61056 100644 --- a/org.glite.security.proxyrenewal/src/renewd.c +++ b/org.glite.security.proxyrenewal/src/renewd.c @@ -546,6 +546,7 @@ int main(int argc, char *argv[]) ctx->log_level = LOG_DEBUG; ctx->log_dst = GLITE_RENEWAL_LOG_STDOUT; } + ctx->voms_conf = vomsconf; if (chdir(repository)) { edg_wlpr_Log(ctx, LOG_ERR, "Cannot access repository directory %s (%s)", diff --git a/org.glite.security.proxyrenewal/src/renewd_locl.h b/org.glite.security.proxyrenewal/src/renewd_locl.h index 71565d4..78c106e 100644 --- a/org.glite.security.proxyrenewal/src/renewd_locl.h +++ b/org.glite.security.proxyrenewal/src/renewd_locl.h @@ -71,7 +71,7 @@ load_proxy(glite_renewal_core_context ctx, const char *filename, X509 **cert, EV STACK_OF(X509) **chain, globus_gsi_cred_handle_t *proxy); int -get_proxy_base_name(glite_renewal_core_context ctx, char *file, char **subject); +get_proxy_base_name(glite_renewal_core_context ctx, const char *file, char **subject); int renew_voms_creds(glite_renewal_core_context ctx, const char *cur_file, const char *renewed_file, const char *new_file); -- 1.8.2.3