summaryrefslogtreecommitdiff
path: root/NK_C_API.cc
diff options
context:
space:
mode:
authorRobin Krahl <me@robin-krahl.de>2019-01-17 00:37:30 +0100
committerRobin Krahl <me@robin-krahl.de>2019-01-17 00:37:30 +0100
commitf6ae756f421f668b53131f7d924a6303f3b99c73 (patch)
treea4269e4c5210339abfb31362e43d2bf29ee633b1 /NK_C_API.cc
parentdee882fd21cd932c2642d170620862e783284d3b (diff)
downloadlibnitrokey-f6ae756f421f668b53131f7d924a6303f3b99c73.tar.gz
libnitrokey-f6ae756f421f668b53131f7d924a6303f3b99c73.tar.bz2
Return firmware version parts as uint8_t instead of int
The firmware version parts returned by the Nitrokey devices are uint8_t values. This is part of the public API as part of the NK_storage_status struct. For consistency with this API, this patch changes the functions NK_get_major_firmware_version and NK_get_minor_firmware_version to return uint8_t instead of int.
Diffstat (limited to 'NK_C_API.cc')
-rw-r--r--NK_C_API.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/NK_C_API.cc b/NK_C_API.cc
index 794673a..c6f04d4 100644
--- a/NK_C_API.cc
+++ b/NK_C_API.cc
@@ -719,14 +719,14 @@ NK_C_API char* NK_get_SD_usage_data_as_string() {
}, -2));
}
- NK_C_API int NK_get_major_firmware_version() {
+ NK_C_API uint8_t NK_get_major_firmware_version() {
auto m = NitrokeyManager::instance();
return get_with_result([&]() {
return m->get_major_firmware_version();
});
}
- NK_C_API int NK_get_minor_firmware_version() {
+ NK_C_API uint8_t NK_get_minor_firmware_version() {
auto m = NitrokeyManager::instance();
return get_with_result([&]() {
return m->get_minor_firmware_version();