lavf/movenc: return meaningful error code from mov_write_header()