mirror of
https://github.com/mpv-player/mpv
synced 2025-01-30 19:52:14 +00:00
stream/network: distinguish EOF/error in streaming control API
Signal EOF vs. error also via streaming control API (not yet evaluated). git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@33806 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
61fe3dcd6c
commit
c89f72b561
@ -467,7 +467,8 @@ nop_streaming_read( int fd, char *buffer, int size, streaming_ctrl_t *stream_ctr
|
||||
ret = recv( fd, buffer+len, size-len, 0 );
|
||||
if( ret<0 ) {
|
||||
mp_msg(MSGT_NETWORK,MSGL_ERR,"nop_streaming_read error : %s\n",strerror(errno));
|
||||
}
|
||||
} else if (ret == 0)
|
||||
stream_ctrl->status = streaming_stopped_e;
|
||||
len += ret;
|
||||
//printf("read %d bytes from network\n", len );
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user