mirror of
https://gitlab.com/cryptsetup/cryptsetup.git
synced 2025-12-14 20:30:04 +01:00
Fix isLuks message (should appear only in verbose mode).
git-svn-id: https://cryptsetup.googlecode.com/svn/trunk@653 36d66b0a-2a48-0410-832c-cd162a569da5
This commit is contained in:
@@ -191,6 +191,13 @@ static void _log(int level, const char *msg, void *usrptr __attribute__((unused)
|
||||
}
|
||||
}
|
||||
|
||||
static void _quiet_log(int level, const char *msg, void *usrptr)
|
||||
{
|
||||
if (!opt_verbose && (level == CRYPT_LOG_ERROR || level == CRYPT_LOG_NORMAL))
|
||||
level = CRYPT_LOG_VERBOSE;
|
||||
_log(level, msg, usrptr);
|
||||
}
|
||||
|
||||
static void show_status(int errcode)
|
||||
{
|
||||
char error[256], *error_;
|
||||
@@ -863,6 +870,7 @@ static int action_isLuks(int arg __attribute__((unused)))
|
||||
if ((r = crypt_init(&cd, action_argv[0])))
|
||||
goto out;
|
||||
|
||||
crypt_set_log_callback(cd, _quiet_log, NULL);
|
||||
r = crypt_load(cd, CRYPT_LUKS1, NULL);
|
||||
out:
|
||||
crypt_free(cd);
|
||||
|
||||
Reference in New Issue
Block a user