kopia lustrzana https://github.com/micropython/micropython
extmod/modussl_mbedtls: Set a more sensible default debug log level.
rodzic
fbe9417b90
commit
1bf2fd0592
|
@ -74,7 +74,7 @@ STATIC const mp_obj_type_t ussl_socket_type;
|
||||||
STATIC void mbedtls_debug(void *ctx, int level, const char *file, int line, const char *str) {
|
STATIC void mbedtls_debug(void *ctx, int level, const char *file, int line, const char *str) {
|
||||||
(void)ctx;
|
(void)ctx;
|
||||||
(void)level;
|
(void)level;
|
||||||
printf("DBG:%s:%04d: %s\n", file, line, str);
|
mp_printf(&mp_plat_print, "DBG:%s:%04d: %s\n", file, line, str);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
@ -175,7 +175,7 @@ STATIC mp_obj_ssl_socket_t *socket_new(mp_obj_t sock, struct ssl_args *args) {
|
||||||
mbedtls_ctr_drbg_init(&o->ctr_drbg);
|
mbedtls_ctr_drbg_init(&o->ctr_drbg);
|
||||||
#ifdef MBEDTLS_DEBUG_C
|
#ifdef MBEDTLS_DEBUG_C
|
||||||
// Debug level (0-4) 1=warning, 2=info, 3=debug, 4=verbose
|
// Debug level (0-4) 1=warning, 2=info, 3=debug, 4=verbose
|
||||||
mbedtls_debug_set_threshold(0);
|
mbedtls_debug_set_threshold(3);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
mbedtls_entropy_init(&o->entropy);
|
mbedtls_entropy_init(&o->entropy);
|
||||||
|
|
Ładowanie…
Reference in New Issue