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
6ab19c7e
Commit
6ab19c7e
authored
Aug 08, 2017
by
Max Kellermann
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
output/Shout: pass shout_t* to handle_shout_error()
parent
d22361f7
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
8 deletions
+8
-8
ShoutOutputPlugin.cxx
src/output/plugins/ShoutOutputPlugin.cxx
+8
-8
No files found.
src/output/plugins/ShoutOutputPlugin.cxx
View file @
6ab19c7e
...
@@ -257,7 +257,7 @@ ShoutOutput::Create(EventLoop &, const ConfigBlock &block)
...
@@ -257,7 +257,7 @@ ShoutOutput::Create(EventLoop &, const ConfigBlock &block)
}
}
static
void
static
void
handle_shout_error
(
ShoutOutput
*
sd
,
int
err
)
HandleShoutError
(
shout_t
*
shout_conn
,
int
err
)
{
{
switch
(
err
)
{
switch
(
err
)
{
case
SHOUTERR_SUCCESS
:
case
SHOUTERR_SUCCESS
:
...
@@ -266,15 +266,15 @@ handle_shout_error(ShoutOutput *sd, int err)
...
@@ -266,15 +266,15 @@ handle_shout_error(ShoutOutput *sd, int err)
case
SHOUTERR_UNCONNECTED
:
case
SHOUTERR_UNCONNECTED
:
case
SHOUTERR_SOCKET
:
case
SHOUTERR_SOCKET
:
throw
FormatRuntimeError
(
"Lost shout connection to %s:%i: %s"
,
throw
FormatRuntimeError
(
"Lost shout connection to %s:%i: %s"
,
shout_get_host
(
s
d
->
s
hout_conn
),
shout_get_host
(
shout_conn
),
shout_get_port
(
s
d
->
s
hout_conn
),
shout_get_port
(
shout_conn
),
shout_get_error
(
s
d
->
s
hout_conn
));
shout_get_error
(
shout_conn
));
default
:
default
:
throw
FormatRuntimeError
(
"connection to %s:%i error: %s"
,
throw
FormatRuntimeError
(
"connection to %s:%i error: %s"
,
shout_get_host
(
s
d
->
s
hout_conn
),
shout_get_host
(
shout_conn
),
shout_get_port
(
s
d
->
s
hout_conn
),
shout_get_port
(
shout_conn
),
shout_get_error
(
s
d
->
s
hout_conn
));
shout_get_error
(
shout_conn
));
}
}
}
}
...
@@ -290,7 +290,7 @@ write_page(ShoutOutput *sd)
...
@@ -290,7 +290,7 @@ write_page(ShoutOutput *sd)
return
true
;
return
true
;
int
err
=
shout_send
(
sd
->
shout_conn
,
sd
->
buffer
,
nbytes
);
int
err
=
shout_send
(
sd
->
shout_conn
,
sd
->
buffer
,
nbytes
);
handle_shout_error
(
sd
,
err
);
HandleShoutError
(
sd
->
shout_conn
,
err
);
}
}
return
true
;
return
true
;
...
...
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