From: Andre Noll Date: Fri, 12 Jun 2009 19:39:38 +0000 (+0200) Subject: Fix checking of return values from osl_open(). X-Git-Tag: v0.4.0~75^2~6 X-Git-Url: http://git.tuebingen.mpg.de/?p=paraslash.git;a=commitdiff_plain;h=d43da48a1e6555b3eaea162f44ea131175acc1f7 Fix checking of return values from osl_open(). --- diff --git a/aft.c b/aft.c index db4c494d..f425b6d3 100644 --- a/aft.c +++ b/aft.c @@ -2574,7 +2574,7 @@ static int aft_open(const char *dir) } PARA_INFO_LOG("failed to open audio file table\n"); audio_file_table = NULL; - if (ret >= 0 || is_errno(-ret, ENOENT)) + if (ret >= 0 || ret == -OSL_ERRNO_TO_PARA_ERROR(E_OSL_NOENT)) return 1; return ret; } diff --git a/attribute.c b/attribute.c index 4784aee9..dc375c1d 100644 --- a/attribute.c +++ b/attribute.c @@ -587,7 +587,7 @@ static int attribute_open(const char *dir) return ret; } attribute_table = NULL; - if (ret >= 0 || is_errno(-ret, ENOENT)) + if (ret >= 0 || ret == -OSL_ERRNO_TO_PARA_ERROR(E_OSL_NOENT)) return 1; return ret; } diff --git a/blob.c b/blob.c index f635eb0d..b4ac2fa4 100644 --- a/blob.c +++ b/blob.c @@ -525,7 +525,7 @@ static int blob_open(struct osl_table **table, if (ret >= 0) return ret; *table = NULL; - if (ret >= 0 || is_errno(-ret, ENOENT)) + if (ret >= 0 || ret == -OSL_ERRNO_TO_PARA_ERROR(E_OSL_NOENT)) return 1; return ret; }