diff options
author | eddyg <[email protected]> | 2007-08-27 02:07:25 +0000 |
---|---|---|
committer | eddyg <[email protected]> | 2007-08-27 02:07:25 +0000 |
commit | 74d6813ce3d07ced59a1426d52a0f87583768e24 (patch) | |
tree | 9dbaaa720df3c636c52218a75916b6d331b6d0e9 | |
parent | 03d32783ea021b5ae8e744f094af90197294327a (diff) |
Fixed up mkv error messages that did not apply, and added one which was missed.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@870 b64f7644-9d1e-0410-96f1-a4d463321fa5
-rw-r--r-- | libhb/muxmkv.c | 20 |
1 files changed, 8 insertions, 12 deletions
diff --git a/libhb/muxmkv.c b/libhb/muxmkv.c index 62a4dd929..cb69efa91 100644 --- a/libhb/muxmkv.c +++ b/libhb/muxmkv.c @@ -271,17 +271,9 @@ static int MKVMux( hb_mux_object_t * m, hb_mux_data_t * mux_data, hb_error( "Failed to write start frame to output file, Disk Full?" ); *job->die = 1; } - if( mk_addFrameData(m->file, mux_data->track, buf->data, buf->size) < 0 ) - { - hb_error( "Failed to write frame data to output file, Disk Full?" ); - *job->die = 1; - } - if( mk_setFrameFlags(m->file, mux_data->track, timecode, - ((job->vcodec == HB_VCODEC_X264 && mux_data == job->mux_data) ? (buf->frametype == HB_FRAME_IDR) : ((buf->frametype & HB_FRAME_KEY) != 0)) ) < 0 ) - { - hb_error( "Failed to write frame flags to output file, Disk Full?" ); - *job->die = 1; - } + mk_addFrameData(m->file, mux_data->track, buf->data, buf->size); + mk_setFrameFlags(m->file, mux_data->track, timecode, + ((job->vcodec == HB_VCODEC_X264 && mux_data == job->mux_data) ? (buf->frametype == HB_FRAME_IDR) : ((buf->frametype & HB_FRAME_KEY) != 0)) ); return 0; } @@ -311,7 +303,11 @@ static int MKVEnd( hb_mux_object_t * m ) mk_createChapterSimple(m->file, mux_data->prev_chapter_tc, mux_data->prev_chapter_tc, string); } - mk_close(m->file); + if( mk_close(m->file) < 0 ) + { + hb_error( "Failed to flush the last frame and close the output file, Disk Full?" ); + *job->die = 1; + } // TODO: Free what we alloc'd |