diff --git a/NEWS b/NEWS index c985e5021..c17b563f2 100644 --- a/NEWS +++ b/NEWS @@ -1,4 +1,6 @@ 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) * input diff --git a/src/PlaylistFile.cxx b/src/PlaylistFile.cxx index 806bbeea0..2deae4321 100644 --- a/src/PlaylistFile.cxx +++ b/src/PlaylistFile.cxx @@ -335,7 +335,7 @@ try { const auto path_fs = spl_map_to_fs(utf8path); 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) throw PlaylistError(PlaylistResult::TOO_LARGE,