Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
mpd
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Иван Мажукин
mpd
Commits
8cf2f52f
Commit
8cf2f52f
authored
Oct 14, 2013
by
Max Kellermann
Browse files
Options
Browse Files
Download
Plain Diff
Merge tag 'release-0.17.6'
parents
17c6db6c
681352ac
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
30 additions
and
4 deletions
+30
-4
NEWS
NEWS
+6
-1
PlaylistFile.cxx
src/PlaylistFile.cxx
+14
-3
PlaylistSave.cxx
src/PlaylistSave.cxx
+10
-0
No files found.
NEWS
View file @
8cf2f52f
...
...
@@ -28,9 +28,14 @@ ver 0.18 (2012/??/??)
* improved decoder/output error reporting
* eliminate timer wakeup on idle MPD
ver 0.17.6 (
not yet released
)
ver 0.17.6 (
2013/10/14
)
* mixer:
- alsa: fix busy loop when USB sound device gets unplugged
* decoder:
- modplug: fix build with Debian package 1:0.8.8.4-4
* stored playlists:
- fix loading playlists with references to local files
- obey filesystem_charset for URLs
ver 0.17.5 (2013/08/04)
* protocol:
...
...
src/PlaylistFile.cxx
View file @
8cf2f52f
...
...
@@ -241,7 +241,13 @@ LoadPlaylistFile(const char *utf8path, Error &error)
if
(
*
s
==
0
||
*
s
==
PLAYLIST_COMMENT
)
continue
;
if
(
!
uri_has_scheme
(
s
))
{
if
(
g_path_is_absolute
(
s
))
{
const
auto
path
=
Path
::
ToUTF8
(
s
);
if
(
path
.
empty
())
continue
;
s
=
g_strconcat
(
"file://"
,
path
.
c_str
(),
NULL
);
}
else
if
(
!
uri_has_scheme
(
s
))
{
char
*
path_utf8
;
path_utf8
=
map_fs_to_utf8
(
s
);
...
...
@@ -249,8 +255,13 @@ LoadPlaylistFile(const char *utf8path, Error &error)
continue
;
s
=
path_utf8
;
}
else
s
=
g_strdup
(
s
);
}
else
{
const
auto
path
=
Path
::
ToUTF8
(
s
);
if
(
path
.
empty
())
continue
;
s
=
g_strdup
(
path
.
c_str
());
}
contents
.
emplace_back
(
s
);
if
(
contents
.
size
()
>=
playlist_max_length
)
...
...
src/PlaylistSave.cxx
View file @
8cf2f52f
...
...
@@ -33,6 +33,8 @@
#include <glib.h>
#include <string.h>
void
playlist_print_song
(
FILE
*
file
,
const
Song
*
song
)
{
...
...
@@ -114,6 +116,14 @@ playlist_load_spl(struct playlist *playlist, struct player_control *pc,
for
(
unsigned
i
=
start_index
;
i
<
end_index
;
++
i
)
{
const
auto
&
uri_utf8
=
contents
[
i
];
if
(
memcmp
(
uri_utf8
.
c_str
(),
"file:///"
,
8
)
==
0
)
{
const
char
*
path_utf8
=
uri_utf8
.
c_str
()
+
7
;
if
(
playlist
->
AppendFile
(
*
pc
,
path_utf8
)
!=
PLAYLIST_RESULT_SUCCESS
)
g_warning
(
"can't add file
\"
%s
\"
"
,
path_utf8
);
continue
;
}
if
((
playlist
->
AppendURI
(
*
pc
,
uri_utf8
.
c_str
()))
!=
PLAYLIST_RESULT_SUCCESS
)
{
/* for windows compatibility, convert slashes */
char
*
temp2
=
g_strdup
(
uri_utf8
.
c_str
());
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment