int pb_protocol_boot_status_len(const struct status *status)
{
- return 4 +
+ return 4 + /* type */
4 + optional_strlen(status->message) +
+ 4 + /* backlog */
4;
}
pos += pb_protocol_serialise_string(pos, status->message);
+ *(bool *)pos = __cpu_to_be32(status->backlog);
+ pos += sizeof(bool);
+
assert(pos <= buf + buf_len);
(void)buf_len;
if (read_string(status, &pos, &len, &status->message))
goto out;
+ /* backlog */
+ status->backlog = *(bool *)pos;
+ pos += sizeof(status->backlog);
+
rc = 0;
out: