Allow log messages to be captured by tincctl.
[tinc] / src / openssl / digest.c
index 88bdeb3..3159e7a 100644 (file)
@@ -41,7 +41,7 @@ bool digest_open_by_name(digest_t *digest, const char *name, int maclength) {
        digest->key = NULL;
 
        if(!digest->digest) {
-               logger(LOG_DEBUG, "Unknown digest name '%s'!", name);
+               logger(DEBUG_ALWAYS, LOG_DEBUG, "Unknown digest name '%s'!", name);
                return false;
        }
 
@@ -54,7 +54,7 @@ bool digest_open_by_nid(digest_t *digest, int nid, int maclength) {
        digest->key = NULL;
 
        if(!digest->digest) {
-               logger(LOG_DEBUG, "Unknown digest nid %d!", nid);
+               logger(DEBUG_ALWAYS, LOG_DEBUG, "Unknown digest nid %d!", nid);
                return false;
        }
 
@@ -95,7 +95,7 @@ bool digest_create(digest_t *digest, const void *indata, size_t inlen, void *out
                if(!EVP_DigestInit(&ctx, digest->digest)
                                || !EVP_DigestUpdate(&ctx, indata, inlen)
                                || !EVP_DigestFinal(&ctx, tmpdata, NULL)) {
-                       logger(LOG_DEBUG, "Error creating digest: %s", ERR_error_string(ERR_get_error(), NULL));
+                       logger(DEBUG_ALWAYS, LOG_DEBUG, "Error creating digest: %s", ERR_error_string(ERR_get_error(), NULL));
                        return false;
                }
        }