From 1fafa440eb80a98d2ae889d7aaf65b3804b7d008 Mon Sep 17 00:00:00 2001 From: Szczepan Zalega Date: Fri, 5 Aug 2016 14:11:58 +0200 Subject: Display general config flags as int Signed-off-by: Szczepan Zalega --- include/stick10_commands.h | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'include') diff --git a/include/stick10_commands.h b/include/stick10_commands.h index 2d52352..b9a249d 100644 --- a/include/stick10_commands.h +++ b/include/stick10_commands.h @@ -317,9 +317,9 @@ class GetStatus : Command { ss << "general_config:\t" << ::nitrokey::misc::hexdump((const char *)(general_config), sizeof general_config); - ss << "numlock:\t" << (uint8_t)numlock << std::endl; - ss << "capslock:\t" << (uint8_t)capslock << std::endl; - ss << "scrolllock:\t" << (uint8_t)scrolllock << std::endl; + ss << "numlock:\t" << (int)numlock << std::endl; + ss << "capslock:\t" << (int)capslock << std::endl; + ss << "scrolllock:\t" << (int)scrolllock << std::endl; ss << "enable_user_password:\t" << (bool) enable_user_password << std::endl; ss << "delete_user_password:\t" << (bool) delete_user_password << std::endl; @@ -596,9 +596,9 @@ class WriteGeneralConfig : Command { }; std::string dissect() const { std::stringstream ss; - ss << "numlock:\t" << (uint8_t)numlock << std::endl; - ss << "capslock:\t" << (uint8_t)capslock << std::endl; - ss << "scrolllock:\t" << (uint8_t)scrolllock << std::endl; + ss << "numlock:\t" << (int)numlock << std::endl; + ss << "capslock:\t" << (int)capslock << std::endl; + ss << "scrolllock:\t" << (int)scrolllock << std::endl; ss << "enable_user_password:\t" << (bool) enable_user_password << std::endl; ss << "delete_user_password:\t" << (bool) delete_user_password << std::endl; return ss.str(); -- cgit v1.2.3