From: Steinar H. Gunderson Date: Sun, 18 Aug 2013 11:46:22 +0000 (+0200) Subject: Fix an issue where rewind-to-HTTP-header would not properly work. X-Git-Tag: 1.0.0~2 X-Git-Url: https://git.sesse.net/?a=commitdiff_plain;ds=sidebyside;h=ee1346294bd78efbba2b4f9108585467eee43f5a;p=cubemap Fix an issue where rewind-to-HTTP-header would not properly work. --- diff --git a/server.cpp b/server.cpp index 4442b34..8790633 100644 --- a/server.cpp +++ b/server.cpp @@ -255,8 +255,9 @@ void Server::set_header(int stream_index, const string &http_header, const strin client_it != clients.end(); ++client_it) { Client *client = &client_it->second; - if (client->state == Client::SENDING_DATA && - client->stream_pos == 0) { + if (client->state == Client::WAITING_FOR_KEYFRAME || + (client->state == Client::SENDING_DATA && + client->stream_pos == 0)) { construct_header(client); } }