Mercurial > mplayer.hg
diff stream/stream_file.c @ 22451:86f7b9cab33b
truncate mencoder's output file if it exists, instead of overwriting just part of it.
author | lorenm |
---|---|
date | Mon, 05 Mar 2007 17:42:25 +0000 |
parents | 829b1f30a07f |
children | d261f5109660 |
line wrap: on
line diff
--- a/stream/stream_file.c Mon Mar 05 13:29:06 2007 +0000 +++ b/stream/stream_file.c Mon Mar 05 17:42:25 2007 +0000 @@ -94,7 +94,7 @@ if(mode == STREAM_READ) m = O_RDONLY; else if(mode == STREAM_WRITE) - m = O_RDWR|O_CREAT; + m = O_RDWR|O_CREAT|O_TRUNC; else { mp_msg(MSGT_OPEN,MSGL_ERR, "[file] Unknown open mode %d\n",mode); m_struct_free(&stream_opts,opts);