From: Marcel Poul Date: Wed, 18 Jan 2012 15:31:50 +0000 (+0000) Subject: make some parameters const. X-Git-Tag: emi-canl-c_R_1_0_0_0~29 X-Git-Url: http://scientific.zcu.cz/git/?a=commitdiff_plain;h=1af8ff665ecc9b9bc2d88540219f71af1992d670;p=jra1mw.git make some parameters const. --- diff --git a/emi.canl.canl-c/src/canl_cert.c b/emi.canl.canl-c/src/canl_cert.c index 913e1a0..6dd10ff 100644 --- a/emi.canl.canl-c/src/canl_cert.c +++ b/emi.canl.canl-c/src/canl_cert.c @@ -2,11 +2,6 @@ #if 0 static int set_cert(glb_ctx *cc, X509 *cert); -#endif -int set_key_file(glb_ctx *cc, EVP_PKEY **to, char *key); -int set_cert_file(glb_ctx *cc, X509 **to, char *cert); - -#if 0 //TODO just stub int do_set_ctx_own_cert(glb_ctx *cc, canl_x509 cert, canl_stack_of_x509 chain, canl_pkey key) @@ -87,7 +82,7 @@ int do_set_ctx_own_cert_file(glb_ctx *cc, char *cert, char *key) return 0; } -int set_key_file(glb_ctx *cc, EVP_PKEY **to, char *key) +int set_key_file(glb_ctx *cc, EVP_PKEY **to, const char *key) { unsigned long ssl_err = 0; int err = 0; @@ -128,7 +123,7 @@ end: return 1; } -int set_cert_file(glb_ctx *cc, X509 **to, char *cert) +int set_cert_file(glb_ctx *cc, X509 **to, const char *cert) { unsigned long ssl_err = 0; int err = 0; diff --git a/emi.canl.canl-c/src/canl_locl.h b/emi.canl.canl-c/src/canl_locl.h index 6e037d4..e332fb1 100644 --- a/emi.canl.canl-c/src/canl_locl.h +++ b/emi.canl.canl-c/src/canl_locl.h @@ -142,7 +142,7 @@ int asyn_getservbyname(int a_family, asyn_result *ares_result,char const *name, /*TODO maybe move to another haeder file*/ int do_set_ctx_own_cert_file(glb_ctx *cc, char *cert, char *key); -int set_key_file(glb_ctx *cc, EVP_PKEY **to, char *key); -int set_cert_file(glb_ctx *cc, X509 **to, char *cert); +int set_key_file(glb_ctx *cc, EVP_PKEY **to, const char *key); +int set_cert_file(glb_ctx *cc, X509 **to, const char *cert); #endif