apr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From yla...@apache.org
Subject svn commit: r1792625 - /apr/apr/trunk/locks/unix/proc_mutex.c
Date Tue, 25 Apr 2017 15:35:55 GMT
Author: ylavic
Date: Tue Apr 25 15:35:55 2017
New Revision: 1792625

URL: http://svn.apache.org/viewvc?rev=1792625&view=rev
Log:
locks: unix: follow up to r1792622.

Indent block previously preserved (for easier review), no functional change.


Modified:
    apr/apr/trunk/locks/unix/proc_mutex.c

Modified: apr/apr/trunk/locks/unix/proc_mutex.c
URL: http://svn.apache.org/viewvc/apr/apr/trunk/locks/unix/proc_mutex.c?rev=1792625&r1=1792624&r2=1792625&view=diff
==============================================================================
--- apr/apr/trunk/locks/unix/proc_mutex.c (original)
+++ apr/apr/trunk/locks/unix/proc_mutex.c Tue Apr 25 15:35:55 2017
@@ -717,30 +717,30 @@ static apr_status_t proc_mutex_pthread_a
 
             proc_pthread_mutex_cond_num_waiters(mutex)++;
             do {
-            if (timeout < 0) {
-                rv = pthread_cond_wait(&proc_pthread_mutex_cond(mutex),
-                                       &proc_pthread_mutex(mutex));
-                if (rv) {
+                if (timeout < 0) {
+                    rv = pthread_cond_wait(&proc_pthread_mutex_cond(mutex),
+                                           &proc_pthread_mutex(mutex));
+                    if (rv) {
 #ifdef HAVE_ZOS_PTHREADS
-                    rv = errno;
+                        rv = errno;
 #endif
-                    break;
+                        break;
+                    }
                 }
-            }
-            else {
-                rv = pthread_cond_timedwait(&proc_pthread_mutex_cond(mutex),
-                                            &proc_pthread_mutex(mutex),
-                                            &abstime);
-                if (rv) {
+                else {
+                    rv = pthread_cond_timedwait(&proc_pthread_mutex_cond(mutex),
+                                                &proc_pthread_mutex(mutex),
+                                                &abstime);
+                    if (rv) {
 #ifdef HAVE_ZOS_PTHREADS
-                    rv = errno;
+                        rv = errno;
 #endif
-                    if (rv == ETIMEDOUT) {
-                        rv = APR_TIMEUP;
+                        if (rv == ETIMEDOUT) {
+                            rv = APR_TIMEUP;
+                        }
+                        break;
                     }
-                    break;
                 }
-            }
             } while (proc_pthread_mutex_cond_locked(mutex));
             proc_pthread_mutex_cond_num_waiters(mutex)--;
         }



Mime
View raw message