pipewire: rtsp-client: reset receive state when connected

Previously, the state used to receive messages from the remote
end was not reset when the client connected, which could
lead to issues if the same client is reused for multiple
connections.
This commit is contained in:
Barnabás Pőcze 2022-09-07 03:24:04 +02:00
parent 2d7eb8678b
commit 56df6fed13

View file

@ -186,6 +186,11 @@ static int handle_connect(struct pw_rtsp_client *client, int fd)
client->connecting = false;
client->wait_status = true;
pw_properties_clear(client->headers);
client->status = 0;
client->line_pos = 0;
pw_rtsp_client_emit_connected(client);
return 0;