We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 89f14db commit 4adc564Copy full SHA for 4adc564
src/meshtastic-pb.h
@@ -8,6 +8,7 @@ size_t pb_encode_to_bytes(uint8_t *destbuf, size_t destbufsize, const pb_msgdesc
8
pb_ostream_t stream = pb_ostream_from_buffer(destbuf, destbufsize);
9
if (!pb_encode(&stream, fields, src_struct)) {
10
Serial.println("Panic: can't encode protobuf");
11
+ return 0;
12
} else {
13
return stream.bytes_written;
14
}
0 commit comments