From: Holger Schemel Date: Sun, 12 Sep 2021 23:10:40 +0000 (+0200) Subject: code cleanup X-Git-Tag: 4.3.0.0~59 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=431e165c85738667ec2bd03e3020d6c4e410d6e4;p=rocksndiamonds.git code cleanup --- diff --git a/src/tape.c b/src/tape.c index d7770329..69356b0b 100644 --- a/src/tape.c +++ b/src/tape.c @@ -1579,15 +1579,13 @@ static int AutoPlayTapesExt(boolean initialize) { autoplay.tape_filename = global.autoplay_leveldir; + if (!fileExists(autoplay.tape_filename)) + Fail("tape file '%s' does not exist", autoplay.tape_filename); + LoadTapeFromFilename(autoplay.tape_filename); if (tape.no_valid_file) - { - if (!fileExists(autoplay.tape_filename)) - Fail("tape file '%s' does not exist", autoplay.tape_filename); - else - Fail("cannot load tape file '%s'", autoplay.tape_filename); - } + Fail("cannot load tape file '%s'", autoplay.tape_filename); if (tape.no_info_chunk) Fail("cannot get levelset from tape file '%s'", autoplay.tape_filename);