added debug message for non-empty psk_identity_hint

This commit is contained in:
Olaf Bergmann 2014-12-03 15:48:43 +01:00
parent 7f19fb932b
commit d2f321e4bf

View File

@ -110,6 +110,10 @@ get_psk_info(struct dtls_context_t *ctx UNUSED_PARAM,
switch (type) {
case DTLS_PSK_IDENTITY:
if (id_len) {
dtls_debug("got psk_identity_hint: '%.*s'\n", id_len, id);
}
if (result_length < psk_id_length) {
dtls_warn("cannot set psk_identity -- buffer too small\n");
return dtls_alert_fatal_create(DTLS_ALERT_INTERNAL_ERROR);