summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--libusb/version_nano.h2
-rw-r--r--tests/init_context.c4
-rw-r--r--tests/set_option.c4
3 files changed, 9 insertions, 1 deletions
diff --git a/libusb/version_nano.h b/libusb/version_nano.h
index 6fd8422..fec9410 100644
--- a/libusb/version_nano.h
+++ b/libusb/version_nano.h
@@ -1 +1 @@
-#define LIBUSB_NANO 11795
+#define LIBUSB_NANO 11796
diff --git a/tests/init_context.c b/tests/init_context.c
index e7a010e..757afe9 100644
--- a/tests/init_context.c
+++ b/tests/init_context.c
@@ -109,7 +109,9 @@ static libusb_testlib_result test_init_context_log_level(void) {
LIBUSB_TEST_RETURN_ON_ERROR(libusb_init_context(&test_ctx, options,
/*num_options=*/1));
+#ifndef ENABLE_DEBUG_LOGGING
LIBUSB_EXPECT(==, test_ctx->debug, LIBUSB_LOG_LEVEL_ERROR);
+#endif
LIBUSB_TEST_CLEAN_EXIT(TEST_STATUS_SUCCESS);
}
@@ -137,7 +139,9 @@ static libusb_testlib_result test_init_context_log_cb(void) {
LIBUSB_TEST_RETURN_ON_ERROR(libusb_init_context(&test_ctx, options,
/*num_options=*/1));
+#ifndef ENABLE_DEBUG_LOGGING
LIBUSB_EXPECT(==, test_ctx->log_handler, test_log_cb);
+#endif
LIBUSB_TEST_CLEAN_EXIT(TEST_STATUS_SUCCESS);
}
diff --git a/tests/set_option.c b/tests/set_option.c
index 3c658c6..df2ae1d 100644
--- a/tests/set_option.c
+++ b/tests/set_option.c
@@ -143,13 +143,17 @@ static libusb_testlib_result test_set_log_level_env(void) {
setenv("LIBUSB_DEBUG", "4", /*overwrite=*/0);
LIBUSB_TEST_RETURN_ON_ERROR(libusb_init_context(&test_ctx, /*options=*/NULL,
/*num_options=*/0));
+#ifndef ENABLE_DEBUG_LOGGING
LIBUSB_EXPECT(==, test_ctx->debug, 4);
+#endif
LIBUSB_TEST_RETURN_ON_ERROR(libusb_set_option(test_ctx,
LIBUSB_OPTION_LOG_LEVEL,
LIBUSB_LOG_LEVEL_ERROR));
/* environment variable should always override LIBUSB_OPTION_LOG_LEVEL if set */
+#ifndef ENABLE_DEBUG_LOGGING
LIBUSB_EXPECT(==, test_ctx->debug, 4);
+#endif
LIBUSB_TEST_CLEAN_EXIT(TEST_STATUS_SUCCESS);
#else