summaryrefslogtreecommitdiff
path: root/test/testlock.c
diff options
context:
space:
mode:
authortrawick <trawick@13f79535-47bb-0310-9956-ffa450edef68>2002-04-11 22:55:41 +0000
committertrawick <trawick@13f79535-47bb-0310-9956-ffa450edef68>2002-04-11 22:55:41 +0000
commit56614e6817778ff2bc75271ed1c29c46258b167e (patch)
tree65aebdf7e7a5cd50430694f8dd9879393099544f /test/testlock.c
parent94b45646f3a990b985af7a67fe73899940067bdf (diff)
downloadlibapr-56614e6817778ff2bc75271ed1c29c46258b167e.tar.gz
allow the testlock program to continue on systems where read/write locks
aren't implemented (e.g., Darwin); there is still useful stuff to test git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@63251 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'test/testlock.c')
-rw-r--r--test/testlock.c12
1 files changed, 9 insertions, 3 deletions
diff --git a/test/testlock.c b/test/testlock.c
index 2daddf4ab..30a225759 100644
--- a/test/testlock.c
+++ b/test/testlock.c
@@ -482,9 +482,15 @@ int main(int argc, const char * const *argv)
}
if ((rv = test_thread_rwlock()) != APR_SUCCESS) {
- fprintf(stderr,"thread_rwlock test failed : [%d] %s\n",
- rv, apr_strerror(rv, (char*)errmsg, 200));
- exit(-6);
+ if (rv == APR_ENOTIMPL) {
+ fprintf(stderr, "read/write locks aren't implemented on this "
+ "platform... skipping those tests...\n");
+ }
+ else {
+ fprintf(stderr,"thread_rwlock test failed : [%d] %s\n",
+ rv, apr_strerror(rv, (char*)errmsg, 200));
+ exit(-6);
+ }
}
if ((rv = test_cond()) != APR_SUCCESS) {