summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libmpdemux/asf_mmst_streaming.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libmpdemux/asf_mmst_streaming.c b/libmpdemux/asf_mmst_streaming.c
index 28ce7ea7f4..dc0a94df91 100644
--- a/libmpdemux/asf_mmst_streaming.c
+++ b/libmpdemux/asf_mmst_streaming.c
@@ -513,11 +513,19 @@ int asf_mmst_streaming_start(stream_t *stream)
URL_t *url1 = stream->streaming_ctrl->url;
int s = stream->fd;
+ if( s>0 ) {
+ close( stream->fd );
+ stream->fd = -1;
+ }
+
/* parse url */
path = strchr(url1->file,'/') + 1;
url1->port=1755;
s = connect2Server( url1->hostname, url1->port );
+ if( s<0 ) {
+ return s;
+ }
printf ("connected\n");
/*