qtdemux: fix deadlock in error code path