Skip to content

Commit 726b08b

Browse files
author
Arto Kinnunen
authored
Adjust NULL string tracing (ARMmbed#1726)
IAR toolchain fails to print NULL string traces. Adjust trace to print (none) when string pointer is NULL.
1 parent 7544ef3 commit 726b08b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

source/6LoWPAN/Thread/thread_leader_service.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1090,7 +1090,7 @@ static int thread_leader_service_petition_cb(int8_t service_id, uint8_t source_a
10901090
ptr = thread_meshcop_tlv_data_write_uint8(ptr, MESHCOP_TLV_STATE, 0xff);
10911091
}
10921092

1093-
tr_debug("Petition req recv id %s, RESP session id: %d ret %d", commissioner_id_ptr, session_id, ret);
1093+
tr_debug("Petition req recv id %s, RESP session id: %d ret %d", commissioner_id_ptr ? commissioner_id_ptr : "(none)", session_id, ret);
10941094

10951095
send_error_response:
10961096
coap_service_response_send(this->coap_service_id, COAP_REQUEST_OPTIONS_NONE, request_ptr, response_code, COAP_CT_OCTET_STREAM, payload, ptr - payload);

0 commit comments

Comments
 (0)