output/shout: fix memory leak in error handler
This commit is contained in:
parent
c392efb481
commit
c7748fedab
3
NEWS
3
NEWS
|
@ -1,5 +1,6 @@
|
||||||
ver 0.17.3 (2012/??/??)
|
ver 0.17.3 (2012/??/??)
|
||||||
|
* output:
|
||||||
|
- shout: fix memory leak in error handler
|
||||||
|
|
||||||
ver 0.17.2 (2012/09/30)
|
ver 0.17.2 (2012/09/30)
|
||||||
* protocol:
|
* protocol:
|
||||||
|
|
|
@ -439,8 +439,13 @@ my_shout_open_device(struct audio_output *ao, struct audio_format *audio_format,
|
||||||
|
|
||||||
sd->buf.len = 0;
|
sd->buf.len = 0;
|
||||||
|
|
||||||
if (!encoder_open(sd->encoder, audio_format, error) ||
|
if (!encoder_open(sd->encoder, audio_format, error)) {
|
||||||
!write_page(sd, error)) {
|
shout_close(sd->shout_conn);
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!write_page(sd, error)) {
|
||||||
|
encoder_close(sd->encoder);
|
||||||
shout_close(sd->shout_conn);
|
shout_close(sd->shout_conn);
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue