Added parentheses to remove nested if-else ambiguity.
authorwtc%netscape.com
Fri, 02 Jun 2000 00:20:31 +0000
changeset 1399 7a35bb265f8c69bdc1fb3559b1f6432bdffe160f
parent 1398 352f88507a6762e04b4f89cd0c9d8f178317f1ca
child 1400 49752e0c37116bfb788c4d4f2df5689bb08b2811
push idunknown
push userunknown
push dateunknown
Added parentheses to remove nested if-else ambiguity.
pr/tests/alarm.c
--- a/pr/tests/alarm.c
+++ b/pr/tests/alarm.c
@@ -203,17 +203,18 @@ static PRBool AlarmFn1(PRAlarmID *id, vo
     if (!late && (interval > 10))
     {
         interval &= (now & 0x03) + 1;
         PR_WaitCondVar(ad->cv, interval);
     }
           
     PR_Unlock(ad->ml);
 
-    if (rv != PR_SUCCESS) {
+    if (rv != PR_SUCCESS)
+    {
 		if (!debug_mode) failed_already=1;
 		else
 		 printf("AlarmFn: notify status: FAIL\n");
 		
 	}
 
     if (resetAlarm)
     {   
@@ -339,20 +340,22 @@ static PRIntervalTime Alarms2(PRUint32 l
     while ((PRIntervalTime)(PR_IntervalNow() - ad.timein) < duration)
         PR_WaitCondVar(cv, PR_INTERVAL_NO_TIMEOUT);
     PR_Unlock(ml);
     
     timein = PR_IntervalNow();
 
     rv = PR_DestroyAlarm(alarm);
     if (rv != PR_SUCCESS)
+    {
 		if (!debug_mode)
 			failed_already=1;
 		else	
 			printf("***Destroying alarm status: FAIL\n");
+    }
 		
 
     PR_DestroyCondVar(cv);
     PR_DestroyLock(ml);
     
     overhead += (PR_IntervalNow() - timein);
     
     return duration + overhead;
@@ -408,17 +411,18 @@ static PRIntervalTime Alarms3(PRUint32 l
     timein = PR_IntervalNow();
 
 	if (debug_mode)
 	printf
         ("Alarms3 finished at %u, %u, %u\n",
         ad[0].timein, ad[1].timein, ad[2].timein);
     
     rv = PR_DestroyAlarm(alarm);
-    if (rv != PR_SUCCESS) {
+    if (rv != PR_SUCCESS)
+    {
 		if (!debug_mode)		
 			failed_already=1;
 		else	
 		   printf("***Destroying alarm status: FAIL\n");
 	}
     PR_DestroyCondVar(cv);
     PR_DestroyLock(ml);