aft.c: Remove condition which is always false.
authorAndre Noll <maan@tuebingen.mpg.de>
Mon, 22 Dec 2014 01:15:19 +0000 (01:15 +0000)
committerAndre Noll <maan@tuebingen.mpg.de>
Sun, 14 Jun 2015 12:14:35 +0000 (14:14 +0200)
aft_open() returns early if ret is non-negative, so ret is known to
be negative at this point.

Upgrade the log message severity on open failure from INFO to NOTICE
while at it.

aft.c

diff --git a/aft.c b/aft.c
index 4893f21..a9bc006 100644 (file)
--- a/aft.c
+++ b/aft.c
@@ -2720,9 +2720,9 @@ static int aft_open(const char *dir)
                PARA_INFO_LOG("audio file table contains %d files\n", num);
                return ret;
        }
-       PARA_INFO_LOG("failed to open audio file table\n");
+       PARA_NOTICE_LOG("failed to open audio file table\n");
        audio_file_table = NULL;
-       if (ret >= 0 || ret == -OSL_ERRNO_TO_PARA_ERROR(E_OSL_NOENT))
+       if (ret == -OSL_ERRNO_TO_PARA_ERROR(E_OSL_NOENT))
                return 1;
        return ret;
 }