mirror of
https://gitlab.xiph.org/xiph/icecast-server.git
synced 2024-12-04 14:46:30 -05:00
indentation fixes, and a small fix for tracking bytes sent.
svn path=/trunk/icecast/; revision=4197
This commit is contained in:
parent
ba5e903735
commit
d8e9eb3883
@ -93,13 +93,15 @@ static int send_metadata(client_t *client, mp3_client_data *client_state,
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
fullmetadata_size = strlen(source_state->metadata) + strlen("StreamTitle='';StreamUrl=''") + 1;
|
fullmetadata_size = strlen(source_state->metadata) +
|
||||||
|
strlen("StreamTitle='';StreamUrl=''") + 1;
|
||||||
|
|
||||||
fullmetadata = alloca(fullmetadata_size);
|
fullmetadata = alloca(fullmetadata_size);
|
||||||
|
|
||||||
memset(fullmetadata, 0, fullmetadata_size);
|
memset(fullmetadata, 0, fullmetadata_size);
|
||||||
|
|
||||||
sprintf(fullmetadata, "StreamTitle='%s';StreamUrl=''", source_state->metadata);
|
sprintf(fullmetadata, "StreamTitle='%s';StreamUrl=''",
|
||||||
|
source_state->metadata);
|
||||||
|
|
||||||
source_age = source_state->metadata_age;
|
source_age = source_state->metadata_age;
|
||||||
send_metadata = source_age != client_state->metadata_age;
|
send_metadata = source_age != client_state->metadata_age;
|
||||||
@ -160,6 +162,8 @@ static int format_mp3_write_buf_to_client(format_plugin_t *self,
|
|||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
ret = send_metadata(client, state, self->_state);
|
ret = send_metadata(client, state, self->_state);
|
||||||
|
if(ret > 0)
|
||||||
|
client->con->sent_bytes += ret;
|
||||||
ret = 0;
|
ret = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user