Commit 18710af1 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

file out: print I/O error to log and fix error handling

parent 4d6f7ee7
......@@ -274,11 +274,12 @@ static ssize_t Write( sout_access_out_t *p_access, block_t *p_buffer )
ssize_t val = write ((intptr_t)p_access->p_sys,
p_buffer->p_buffer, p_buffer->i_buffer);
if (val == -1)
if (val <= 0)
if (errno == EINTR)
block_ChainRelease (p_buffer);
msg_Err( p_access, "cannot write: %m" );
return -1;
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment