summaryrefslogtreecommitdiff
path: root/src/veritysetup/veritysetup.c
diff options
context:
space:
mode:
authorLuca Boccassi <luca.boccassi@microsoft.com>2020-08-10 11:45:07 +0100
committerLuca Boccassi <luca.boccassi@microsoft.com>2020-08-14 15:26:04 +0100
commitefc3b12fdbe38f023b70839df5653ecae5ce44d3 (patch)
tree7c73597944837d2fd2f7faea7eb734fcbf716640 /src/veritysetup/veritysetup.c
parentecab4c470cae07a65a10e9aa2aec3878a06f2904 (diff)
downloadsystemd-efc3b12fdbe38f023b70839df5653ecae5ce44d3.tar.gz
tree-wide: enable/disable libcrypsetup debug output depending on our level
Avoid always setting to debug, as it will incur in many more callbacks from libcrypsetup that then get discarded, wasting resources.
Diffstat (limited to 'src/veritysetup/veritysetup.c')
-rw-r--r--src/veritysetup/veritysetup.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/veritysetup/veritysetup.c b/src/veritysetup/veritysetup.c
index e475402d9d..753777b6ad 100644
--- a/src/veritysetup/veritysetup.c
+++ b/src/veritysetup/veritysetup.c
@@ -73,7 +73,7 @@ static int run(int argc, char *argv[]) {
if (r < 0)
return log_error_errno(r, "Failed to open verity device %s: %m", argv[4]);
- crypt_set_log_callback(cd, cryptsetup_log_glue, NULL);
+ cryptsetup_enable_logging(cd);
status = crypt_status(cd, argv[2]);
if (IN_SET(status, CRYPT_ACTIVE, CRYPT_BUSY)) {
@@ -124,7 +124,7 @@ static int run(int argc, char *argv[]) {
if (r < 0)
return log_error_errno(r, "crypt_init_by_name() failed: %m");
- crypt_set_log_callback(cd, cryptsetup_log_glue, NULL);
+ cryptsetup_enable_logging(cd);
r = crypt_deactivate(cd, argv[2]);
if (r < 0)