Fix silent failure of importing OGG Vorbis files
When importing non-valid OGG Vorbis audio files, now the filesystem navigation tree shows the correct sad red-face icon, as it does with non-valid PNG, JPG or WAV files. Fix #9793.
This commit is contained in:
parent
4f1b87265e
commit
a8d37de461
1 changed files with 1 additions and 0 deletions
|
@ -100,6 +100,7 @@ Error ResourceImporterOGGVorbis::import(const String &p_source_file, const Strin
|
||||||
ogg_stream.instance();
|
ogg_stream.instance();
|
||||||
|
|
||||||
ogg_stream->set_data(data);
|
ogg_stream->set_data(data);
|
||||||
|
ERR_FAIL_COND_V(!ogg_stream->get_data().size(), ERR_FILE_CORRUPT);
|
||||||
ogg_stream->set_loop(loop);
|
ogg_stream->set_loop(loop);
|
||||||
ogg_stream->set_loop_offset(loop_offset);
|
ogg_stream->set_loop_offset(loop_offset);
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue