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
46c19b82
Commit
46c19b82
authored
Jul 05, 2009
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
song_print: send song modification time to client
Added the response line "Last-Modified", which sends the modification time in ISO 8601. The same was already implemented for playlists.
parent
077b24d6
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
19 additions
and
0 deletions
+19
-0
NEWS
NEWS
+2
-0
song_print.c
src/song_print.c
+17
-0
No files found.
NEWS
View file @
46c19b82
ver 0.16 (20??/??/??)
* protocol:
- send song modification time to client
* decoders:
- ffmpeg: support multiple tags
* mixers:
...
...
src/song_print.c
View file @
46c19b82
...
...
@@ -50,6 +50,23 @@ song_print_info(struct client *client, struct song *song)
{
song_print_url
(
client
,
song
);
if
(
song
->
mtime
>
0
)
{
time_t
t
=
song
->
mtime
;
#ifndef G_OS_WIN32
struct
tm
tm
;
#endif
char
timestamp
[
32
];
strftime
(
timestamp
,
sizeof
(
timestamp
),
"%FT%TZ"
,
#ifdef G_OS_WIN32
gmtime
(
&
t
)
#else
gmtime_r
(
&
t
,
&
tm
)
#endif
);
client_printf
(
client
,
"Last-Modified: %s
\n
"
,
timestamp
);
}
if
(
song
->
tag
)
tag_print
(
client
,
song
->
tag
);
...
...
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