PlaylistFile: "playlistadd" creates new playlist if it does not exist, as documented
This commit is contained in:
parent
5677278251
commit
dcbab8e37a
2
NEWS
2
NEWS
|
@ -1,4 +1,6 @@
|
||||||
ver 0.20.3 (not yet released)
|
ver 0.20.3 (not yet released)
|
||||||
|
* protocol
|
||||||
|
- "playlistadd" creates new playlist if it does not exist, as documented
|
||||||
|
|
||||||
ver 0.20.2 (2017/01/15)
|
ver 0.20.2 (2017/01/15)
|
||||||
* input
|
* input
|
||||||
|
|
|
@ -335,7 +335,7 @@ try {
|
||||||
const auto path_fs = spl_map_to_fs(utf8path);
|
const auto path_fs = spl_map_to_fs(utf8path);
|
||||||
assert(!path_fs.IsNull());
|
assert(!path_fs.IsNull());
|
||||||
|
|
||||||
FileOutputStream fos(path_fs, FileOutputStream::Mode::APPEND_EXISTING);
|
FileOutputStream fos(path_fs, FileOutputStream::Mode::APPEND_OR_CREATE);
|
||||||
|
|
||||||
if (fos.Tell() / (MPD_PATH_MAX + 1) >= playlist_max_length)
|
if (fos.Tell() / (MPD_PATH_MAX + 1) >= playlist_max_length)
|
||||||
throw PlaylistError(PlaylistResult::TOO_LARGE,
|
throw PlaylistError(PlaylistResult::TOO_LARGE,
|
||||||
|
|
Loading…
Reference in New Issue