/*
* Make sure at least one bit is available for this packet. An
* empty packet is impossible. If we reach the end of the medium
* at this point, then it's considered the end of the stream.
*/
/*
* Make sure at least one bit is available for this packet. An
* empty packet is impossible. If we reach the end of the medium
* at this point, then it's considered the end of the stream.
*/
BT_COMP_LOGD("Decoding packet header field:"
"notit-addr=%p, trace-class-addr=%p, fc-addr=%p",
notit, notit->meta.tc, packet_header_fc);
BT_COMP_LOGD("Decoding packet header field:"
"notit-addr=%p, trace-class-addr=%p, fc-addr=%p",
notit, notit->meta.tc, packet_header_fc);
STATE_AFTER_TRACE_PACKET_HEADER,
STATE_DSCOPE_TRACE_PACKET_HEADER_CONTINUE, NULL);
STATE_AFTER_TRACE_PACKET_HEADER,
STATE_DSCOPE_TRACE_PACKET_HEADER_CONTINUE, NULL);
BT_COMP_LOGW("Cannot decode packet header field: "
"notit-addr=%p, trace-class-addr=%p, "
"fc-addr=%p",
BT_COMP_LOGW("Cannot decode packet header field: "
"notit-addr=%p, trace-class-addr=%p, "
"fc-addr=%p",
enum bt_msg_iter_medium_status medium_status;
BT_ASSERT(notit);
if (offset < 0) {
BT_COMP_LOGE("Cannot seek to negative offset: offset=%jd", (intmax_t) offset);
enum bt_msg_iter_medium_status medium_status;
BT_ASSERT(notit);
if (offset < 0) {
BT_COMP_LOGE("Cannot seek to negative offset: offset=%jd", (intmax_t) offset);
BT_MSG_ITER_SEEK_WHENCE_SET, offset, notit->medium.data);
if (medium_status != BT_MSG_ITER_MEDIUM_STATUS_OK) {
if (medium_status == BT_MSG_ITER_MEDIUM_STATUS_EOF) {
BT_MSG_ITER_SEEK_WHENCE_SET, offset, notit->medium.data);
if (medium_status != BT_MSG_ITER_MEDIUM_STATUS_OK) {
if (medium_status == BT_MSG_ITER_MEDIUM_STATUS_EOF) {