mirror of
https://github.com/obgm/libcoap.git
synced 2026-11-03 08:25:47 +03:00
Set up coap_log_t as an enum, using syslog variable names prefixed by COAP_. Add function coap_dtls_log() for logging information from (D)TLS libraries. Update the log output to have use Lower-case variants for the logging levels to indicate that output is from the (D)TLS library instead of the CoAP library. (D)TLS libraries updated to be consistent in the usage of coap_dtls_set_log_level()/coap_dtls_get_log_level(). Add in coap_log_emerg(), coap_log_alert() etc. as wrappers to reduce the line length required for log entries. Updating all the coap_log() functions to no longer use syslog variants will be a part of a separate PR. Added in the "-V" option to the examples, with an initial default of COAP_LOG_ERR, separating out the CoAP and (D)TLS logging levels. Note: TinyDTLS log output will be consistent when built against a TinyDTLS version that contains support for an external logging handler.