From 2102a29cb047b761ead7cd7e5941e7ef393e4c29 Mon Sep 17 00:00:00 2001 From: jhurst Date: Wed, 3 Oct 2018 18:15:32 +0000 Subject: o Fixed bugs reported by Dolby: bad assert test when writing GS partition unset frame count in ISXD unwrap bad UL when writing ISXF content packages --- src/h__Writer.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/h__Writer.cpp') diff --git a/src/h__Writer.cpp b/src/h__Writer.cpp index 97c6fc2..99d835a 100755 --- a/src/h__Writer.cpp +++ b/src/h__Writer.cpp @@ -193,7 +193,12 @@ ASDCP::AddDmsTrackGenericPartUtf8Text(Kumu::FileWriter& file_writer, MXF::OP1aHe } } - assert(max_sid>1); + if ( max_sid == 0 ) + { + DefaultLogSink().Error("Unable to add a GS Partition before the essence container has been established.\n"); + return RESULT_FORMAT; + } + rip.PairArray.push_back(RIP::PartitionPair(max_sid + 1, file_writer.Tell())); // Add new GSTBS linked to DMF -- cgit v1.2.3