]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Constify crypto_pk_get_digest().
authorGeorge Kadianakis <desnacked@riseup.net>
Mon, 1 Dec 2014 16:12:05 +0000 (16:12 +0000)
committerGeorge Kadianakis <desnacked@riseup.net>
Tue, 2 Dec 2014 12:15:11 +0000 (12:15 +0000)
src/common/crypto.c
src/common/crypto.h

index 7138ba003e6adbe0109801144d8dfba594b577a8..713e5884125a45c162fd11170483bc4bb2bf0d2b 100644 (file)
@@ -1293,7 +1293,7 @@ crypto_pk_asn1_decode(const char *str, size_t len)
  * Return 0 on success, -1 on failure.
  */
 int
-crypto_pk_get_digest(crypto_pk_t *pk, char *digest_out)
+crypto_pk_get_digest(const crypto_pk_t *pk, char *digest_out)
 {
   unsigned char *buf = NULL;
   int len;
index d4965218490915f5677b5191d8fa37d180158455..a8f0fbc975c9804fe285fd6d1ec4422611937c01 100644 (file)
@@ -180,7 +180,7 @@ int crypto_pk_private_hybrid_decrypt(crypto_pk_t *env, char *to,
 
 int crypto_pk_asn1_encode(crypto_pk_t *pk, char *dest, size_t dest_len);
 crypto_pk_t *crypto_pk_asn1_decode(const char *str, size_t len);
-int crypto_pk_get_digest(crypto_pk_t *pk, char *digest_out);
+int crypto_pk_get_digest(const crypto_pk_t *pk, char *digest_out);
 int crypto_pk_get_all_digests(crypto_pk_t *pk, digests_t *digests_out);
 int crypto_pk_get_fingerprint(crypto_pk_t *pk, char *fp_out,int add_space);
 int crypto_pk_get_hashed_fingerprint(crypto_pk_t *pk, char *fp_out);