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
c52f469c
Commit
c52f469c
authored
Apr 05, 2010
by
James Pike
Committed by
Max Kellermann
Apr 05, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
output/httpd: added name/genre/website configuration
parent
50c0c4b7
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
26 additions
and
5 deletions
+26
-5
NEWS
NEWS
+1
-0
httpd_client.c
src/output/httpd_client.c
+6
-5
httpd_internal.h
src/output/httpd_internal.h
+13
-0
httpd_output_plugin.c
src/output/httpd_output_plugin.c
+6
-0
No files found.
NEWS
View file @
c52f469c
...
...
@@ -55,6 +55,7 @@ ver 0.16 (20??/??/??)
- jack: renamed option "ports" to "destination_ports"
- jack: support more than two audio channels
- httpd: bind port when output is enabled
- httpd: added name/genre/website configuration
- wildcards allowed in audio_format configuration
- consistently lock audio output objects
* player:
...
...
src/output/httpd_client.c
View file @
c52f469c
...
...
@@ -282,11 +282,12 @@ httpd_client_send_response(struct httpd_client *client)
}
else
{
gchar
*
metadata_header
;
metadata_header
=
icy_server_metadata_header
(
"Add config information here!"
,
/* TODO */
"Add config information here!"
,
/* TODO */
"Add config information here!"
,
/* TODO */
client
->
httpd
->
content_type
,
client
->
metaint
);
metadata_header
=
icy_server_metadata_header
(
client
->
httpd
->
name
,
client
->
httpd
->
genre
,
client
->
httpd
->
website
,
client
->
httpd
->
content_type
,
client
->
metaint
);
g_strlcpy
(
buffer
,
metadata_header
,
sizeof
(
buffer
));
...
...
src/output/httpd_internal.h
View file @
c52f469c
...
...
@@ -99,6 +99,19 @@ struct httpd_output {
struct
page
*
metadata
;
/**
* The configured name.
*/
char
const
*
name
;
/**
* The configured genre.
*/
char
const
*
genre
;
/**
* The configured website address.
*/
char
const
*
website
;
/**
* A linked list containing all clients which are currently
* connected.
*/
...
...
src/output/httpd_output_plugin.c
View file @
c52f469c
...
...
@@ -111,6 +111,12 @@ httpd_output_init(G_GNUC_UNUSED const struct audio_format *audio_format,
struct
sockaddr_in
*
sin
;
/* read configuration */
httpd
->
name
=
config_get_block_string
(
param
,
"name"
,
"Set name in config"
);
httpd
->
genre
=
config_get_block_string
(
param
,
"genre"
,
"Set genre in config"
);
httpd
->
website
=
config_get_block_string
(
param
,
"website"
,
"Set website in config"
);
port
=
config_get_block_unsigned
(
param
,
"port"
,
8000
);
...
...
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