We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 4e81de9 commit d6d757fCopy full SHA for d6d757f
examples/freertos_plus_tcp/z_scout.c
@@ -20,13 +20,14 @@
20
21
#include "FreeRTOS.h"
22
23
-void fprintzid(FILE *stream, z_bytes_t zid) {
24
- if (zid.start == NULL) {
+void fprintzid(FILE *stream, z_id_t zid) {
+ unsigned int zidlen = _z_id_len(zid);
25
+ if (zidlen == 0) {
26
fprintf(stream, "None");
27
} else {
28
fprintf(stream, "Some(");
- for (unsigned int i = 0; i < zid.len; i++) {
29
- fprintf(stream, "%02X", (int)zid.start[i]);
+ for (unsigned int i = 0; i < zidlen; i++) {
30
+ fprintf(stream, "%02X", (int)zid.id[i]);
31
}
32
fprintf(stream, ")");
33
0 commit comments