Make sure stream->fd is set correct (esp. to -1 on error when fd is closed)

git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@21581 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
reimar 2006-12-10 19:35:39 +00:00
parent be3c6ae324
commit ee08a2d2d3
1 changed files with 2 additions and 1 deletions

View File

@ -744,7 +744,6 @@ static int http_streaming_start(stream_t *stream, int* file_format) {
goto err_out;
}
stream->fd=fd;
if( mp_msg_test(MSGT_NETWORK,MSGL_V) ) {
http_debug_hdr( http_hdr );
}
@ -857,9 +856,11 @@ static int http_streaming_start(stream_t *stream, int* file_format) {
err_out:
if (fd > 0) closesocket( fd );
fd = -1;
res = -1;
http_free( http_hdr );
out:
stream->fd = fd;
return res;
}