TextInputStream: manually shift the buffer before reading

Fixes truncated lines in m3u and cue files (regression by commit
67958f7).
This commit is contained in:
Max Kellermann 2014-10-19 00:50:52 +02:00
parent 063d369672
commit 493cd866f1
2 changed files with 3 additions and 0 deletions

1
NEWS
View File

@ -3,6 +3,7 @@ ver 0.19.1 (not yet released)
- mms: fix deadlock bug
* playlist
- extm3u: fix Extended M3U detection
- m3u, extm3u, cue: fix truncated lines
* fix build failure on Mac OS X
* add missing file systemd/mpd.socket to tarball

View File

@ -33,6 +33,8 @@ TextInputStream::ReadLine()
if (line != nullptr)
return line;
buffer.Shift();
while (true) {
auto dest = buffer.Write();
if (dest.size < 2) {