mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
avb: reply with advertise to discover
This commit is contained in:
parent
a34417eed0
commit
dec2bdf241
1 changed files with 9 additions and 6 deletions
|
|
@ -139,12 +139,15 @@ static int adp_message(void *data, uint64_t now, const void *message, int len)
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case AVB_ADP_MESSAGE_TYPE_ENTITY_DISCOVER:
|
case AVB_ADP_MESSAGE_TYPE_ENTITY_DISCOVER:
|
||||||
if (entity_id == 0UL ||
|
pw_log_info("entity %s advertise",
|
||||||
(e != NULL && e->advertise &&
|
|
||||||
be64toh(e->packet.entity_id) == entity_id)) {
|
|
||||||
pw_log_info("entity %s discover",
|
|
||||||
avb_utils_format_id(buf, sizeof(buf), entity_id));
|
avb_utils_format_id(buf, sizeof(buf), entity_id));
|
||||||
send_discover(adp, entity_id);
|
if (entity_id == 0UL) {
|
||||||
|
spa_list_for_each(e, &adp->entities, link)
|
||||||
|
if (e->advertise)
|
||||||
|
send_advertise(adp, now, e);
|
||||||
|
} else if (e != NULL && e->advertise &&
|
||||||
|
be64toh(e->packet.entity_id) == entity_id) {
|
||||||
|
send_advertise(adp, now, e);
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue