aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--NK_C_API.cc8
-rw-r--r--NK_C_API_helpers.h1
-rw-r--r--NK_C_API_otp.cpp1
-rw-r--r--NK_C_API_pws.cpp1
-rw-r--r--NitrokeyManager.cc1
-rw-r--r--NitrokeyManagerPWS.cc1
-rw-r--r--device.cc1
7 files changed, 7 insertions, 7 deletions
diff --git a/NK_C_API.cc b/NK_C_API.cc
index 5460a92..951532b 100644
--- a/NK_C_API.cc
+++ b/NK_C_API.cc
@@ -20,7 +20,9 @@
*/
#include "NK_C_API.h"
+#ifndef NO_LOG
#include <iostream>
+#endif
#include <tuple>
#include "libnitrokey/NitrokeyManager.h"
#include <cstring>
@@ -63,11 +65,15 @@ extern "C" {
}
catch (const DeviceCommunicationException &deviceException){
NK_last_command_status = 256-deviceException.getType();
+#ifndef NO_LOG
cerr << deviceException.what() << endl;
+#endif
return 0;
}
catch (std::runtime_error &e) {
- cerr << e.what() << endl;
+#ifndef NO_LOG
+ cerr << e.what() << endl;
+#endif
return 0;
}
return 0;
diff --git a/NK_C_API_helpers.h b/NK_C_API_helpers.h
index c5241be..3cb110b 100644
--- a/NK_C_API_helpers.h
+++ b/NK_C_API_helpers.h
@@ -3,7 +3,6 @@
#include "NK_C_API.h"
-#include <iostream>
#include <tuple>
#include "libnitrokey/NitrokeyManager.h"
#include <cstring>
diff --git a/NK_C_API_otp.cpp b/NK_C_API_otp.cpp
index cc44ffc..c1f2e1b 100644
--- a/NK_C_API_otp.cpp
+++ b/NK_C_API_otp.cpp
@@ -10,7 +10,6 @@
#include "libnitrokey/stick20_commands.h"
#include "libnitrokey/version.h"
#include <cstring>
-#include <iostream>
#include <tuple>
#include "nk_strndup.h"
diff --git a/NK_C_API_pws.cpp b/NK_C_API_pws.cpp
index 27ca406..d3df05d 100644
--- a/NK_C_API_pws.cpp
+++ b/NK_C_API_pws.cpp
@@ -10,7 +10,6 @@
#include "libnitrokey/stick20_commands.h"
#include "libnitrokey/version.h"
#include <cstring>
-#include <iostream>
#include <tuple>
#include "nk_strndup.h"
diff --git a/NitrokeyManager.cc b/NitrokeyManager.cc
index 0d566d2..15fbdf1 100644
--- a/NitrokeyManager.cc
+++ b/NitrokeyManager.cc
@@ -29,7 +29,6 @@
#include <algorithm>
#include <cstring>
#include <functional>
-#include <iostream>
#include <mutex>
#include <stick10_commands.h>
#include <stick20_commands.h>
diff --git a/NitrokeyManagerPWS.cc b/NitrokeyManagerPWS.cc
index 5e7c9b7..c4a47eb 100644
--- a/NitrokeyManagerPWS.cc
+++ b/NitrokeyManagerPWS.cc
@@ -7,7 +7,6 @@
#include <algorithm>
#include <cstring>
#include <functional>
-#include <iostream>
#include <mutex>
#include <stick10_commands.h>
#include <stick20_commands.h>
diff --git a/device.cc b/device.cc
index 1204c1e..fc65feb 100644
--- a/device.cc
+++ b/device.cc
@@ -21,7 +21,6 @@
#include <chrono>
#include <codecvt>
-#include <iostream>
#include <locale>
#include <thread>
#include <cstddef>