Song: GetURI() returns std::string

This commit is contained in:
Max Kellermann
2013-10-17 01:01:15 +02:00
parent 67ae033de7
commit be8ceae6e6
10 changed files with 62 additions and 86 deletions

View File

@@ -461,12 +461,10 @@ Player::CheckDecoderStartup()
decoder_starting = false;
if (!paused && !OpenOutput()) {
char *uri = dc.song->GetURI();
const auto uri = dc.song->GetURI();
FormatError(player_domain,
"problems opening audio device "
"while playing \"%s\"", uri);
g_free(uri);
"while playing \"%s\"", uri.c_str());
return true;
}
@@ -878,9 +876,10 @@ Player::SongBorder()
{
xfade_state = CrossFadeState::UNKNOWN;
char *uri = song->GetURI();
FormatInfo(player_domain, "played \"%s\"", uri);
g_free(uri);
{
const auto uri = song->GetURI();
FormatInfo(player_domain, "played \"%s\"", uri.c_str());
}
ReplacePipe(dc.pipe);