Nice catch. Changed the patch to initialize variables in mkv_write_header. Also checking for duration_offset > 0 before writing them as tags in the end, to ensure it won't be written for webm.