summaryrefslogtreecommitdiffstats
path: root/mplayer.c
diff options
context:
space:
mode:
authorarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-08-29 20:11:43 +0000
committerarpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-08-29 20:11:43 +0000
commitee38afc1ad03c30ce98f98c0605739b892145b70 (patch)
treeba8cd89145631a91a3b414e24354cc332d6f842d /mplayer.c
parent8a9c9cd43fdcab6b4afd2f525a96a9fa0a0fd141 (diff)
downloadmpv-ee38afc1ad03c30ce98f98c0605739b892145b70.tar.bz2
mpv-ee38afc1ad03c30ce98f98c0605739b892145b70.tar.xz
can't dump stream if it isn't stream - tip by Ross Finlayson <finlayson@live.com>
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7143 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'mplayer.c')
-rw-r--r--mplayer.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/mplayer.c b/mplayer.c
index a9bcf50d10..e7fb868c3a 100644
--- a/mplayer.c
+++ b/mplayer.c
@@ -1001,6 +1001,10 @@ if(stream_dump_type==5){
int len;
FILE *f;
current_module="dumpstream";
+ if(stream->fd<0){
+ mp_msg(MSGT_CPLAYER,MSGL_FATAL,"Cannot dump this stream - no 'fd' available\n");
+ exit_player(MSGTR_Exit_error);
+ }
stream_reset(stream);
stream_seek(stream,stream->start_pos);
f=fopen(stream_dump_name,"wb");