Module Name:    src
Committed By:   joerg
Date:           Tue May 24 13:08:17 UTC 2011

Modified Files:
        src/usr.sbin/mopd/common: dl.c print.c put.c rc.c
        src/usr.sbin/mopd/mopd: process.c

Log Message:
Kill redundant ()


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/usr.sbin/mopd/common/dl.c
cvs rdiff -u -r1.6 -r1.7 src/usr.sbin/mopd/common/print.c \
    src/usr.sbin/mopd/common/put.c src/usr.sbin/mopd/common/rc.c
cvs rdiff -u -r1.17 -r1.18 src/usr.sbin/mopd/mopd/process.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/usr.sbin/mopd/common/dl.c
diff -u src/usr.sbin/mopd/common/dl.c:1.7 src/usr.sbin/mopd/common/dl.c:1.8
--- src/usr.sbin/mopd/common/dl.c:1.7	Tue Nov 17 18:58:07 2009
+++ src/usr.sbin/mopd/common/dl.c	Tue May 24 13:08:16 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: dl.c,v 1.7 2009/11/17 18:58:07 drochner Exp $	*/
+/*	$NetBSD: dl.c,v 1.8 2011/05/24 13:08:16 joerg Exp $	*/
 
 /*
  * Copyright (c) 1993-95 Mats O Jansson.  All rights reserved.
@@ -26,7 +26,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: dl.c,v 1.7 2009/11/17 18:58:07 drochner Exp $");
+__RCSID("$NetBSD: dl.c,v 1.8 2011/05/24 13:08:16 joerg Exp $");
 #endif
 
 #include "os.h"
@@ -189,7 +189,7 @@
 		
 		tmpc = mopGetChar(pkt,&idx);	/* Error */
 		(void)fprintf(fd,"Error        :   %02x (",tmpc);
-		if ((tmpc == 0)) {
+		if (tmpc == 0) {
 			(void)fprintf(fd,"no error)\n");
 		} else {
 		  	(void)fprintf(fd,"error)\n");

Index: src/usr.sbin/mopd/common/print.c
diff -u src/usr.sbin/mopd/common/print.c:1.6 src/usr.sbin/mopd/common/print.c:1.7
--- src/usr.sbin/mopd/common/print.c:1.6	Tue Nov 17 18:58:07 2009
+++ src/usr.sbin/mopd/common/print.c	Tue May 24 13:08:16 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: print.c,v 1.6 2009/11/17 18:58:07 drochner Exp $	*/
+/*	$NetBSD: print.c,v 1.7 2011/05/24 13:08:16 joerg Exp $	*/
 
 /*
  * Copyright (c) 1993-96 Mats O Jansson.  All rights reserved.
@@ -26,7 +26,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: print.c,v 1.6 2009/11/17 18:58:07 drochner Exp $");
+__RCSID("$NetBSD: print.c,v 1.7 2011/05/24 13:08:16 joerg Exp $");
 #endif
 
 #include <sys/types.h>
@@ -523,18 +523,18 @@
 		case MOP_K_INFO_SFID:
 			tmpc = mopGetChar(pkt,idx);
 			(void)fprintf(fd,"Software ID  :   %02x ",tmpc);
-			if ((tmpc == 0)) {
+			if (tmpc == 0) {
 				(void)fprintf(fd,"No software id");
 			}
-			if ((tmpc == 254)) {
+			if (tmpc == 254) {
 				(void)fprintf(fd,"Maintenance system");
 				tmpc = 0;
 			}
-			if ((tmpc == 255)) {
+			if (tmpc == 255) {
 				(void)fprintf(fd,"Standard operating system");
 				tmpc = 0;
 			}
-			if ((tmpc > 0)) {
+			if (tmpc > 0) {
 				(void)fprintf(fd,"'");
 				for (i = 0; i < ((int) tmpc); i++) {
 					(void)fprintf(fd,"%c",
Index: src/usr.sbin/mopd/common/put.c
diff -u src/usr.sbin/mopd/common/put.c:1.6 src/usr.sbin/mopd/common/put.c:1.7
--- src/usr.sbin/mopd/common/put.c:1.6	Tue Nov 17 18:58:07 2009
+++ src/usr.sbin/mopd/common/put.c	Tue May 24 13:08:16 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: put.c,v 1.6 2009/11/17 18:58:07 drochner Exp $	*/
+/*	$NetBSD: put.c,v 1.7 2011/05/24 13:08:16 joerg Exp $	*/
 
 /*
  * Copyright (c) 1993-95 Mats O Jansson.  All rights reserved.
@@ -26,7 +26,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: put.c,v 1.6 2009/11/17 18:58:07 drochner Exp $");
+__RCSID("$NetBSD: put.c,v 1.7 2011/05/24 13:08:16 joerg Exp $");
 #endif
 
 #include "os.h"
@@ -79,7 +79,7 @@
 	time_t tnow;
 	struct tm *timenow;
 
-	if ((value == 0)) {
+	if (value == 0) {
 	  tnow = time(NULL);
 	} else {
 	  tnow = value;
Index: src/usr.sbin/mopd/common/rc.c
diff -u src/usr.sbin/mopd/common/rc.c:1.6 src/usr.sbin/mopd/common/rc.c:1.7
--- src/usr.sbin/mopd/common/rc.c:1.6	Tue Nov 17 18:58:07 2009
+++ src/usr.sbin/mopd/common/rc.c	Tue May 24 13:08:16 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: rc.c,v 1.6 2009/11/17 18:58:07 drochner Exp $	*/
+/*	$NetBSD: rc.c,v 1.7 2011/05/24 13:08:16 joerg Exp $	*/
 
 /*
  * Copyright (c) 1993-95 Mats O Jansson.  All rights reserved.
@@ -26,7 +26,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: rc.c,v 1.6 2009/11/17 18:58:07 drochner Exp $");
+__RCSID("$NetBSD: rc.c,v 1.7 2011/05/24 13:08:16 joerg Exp $");
 #endif
 
 #include "os.h"
@@ -68,7 +68,7 @@
 		break;
 	case MOP_K_CODE_BOT:
 		
-		if ((moplen == 5)) {
+		if (moplen == 5) {
 			tmps = mopGetShort(pkt,&idx);
 			(void)fprintf(fd,"Verification : %04x\n",tmps);
 		} else {
@@ -111,18 +111,18 @@
 			
 			tmpc = mopGetChar(pkt,&idx);      /* Software ID */
 			(void)fprintf(fd,"Software ID  :   %02x ",tmpc);
-			if ((tmpc == 0)) {
+			if (tmpc == 0) {
 				(void)fprintf(fd,"No software id");
 			}
-			if ((tmpc == 254)) {
+			if (tmpc == 254) {
 				(void)fprintf(fd,"Maintenance system");
 				tmpc = 0;
 			}
-			if ((tmpc == 255)) {
+			if (tmpc == 255) {
 				(void)fprintf(fd,"Standard operating system");
 				tmpc = 0;
 			}
-			if ((tmpc > 0)) {
+			if (tmpc > 0) {
 				(void)fprintf(fd,"'");
 				for (i = 0; i < ((int) tmpc); i++) {
 					(void)fprintf(fd,"%c",

Index: src/usr.sbin/mopd/mopd/process.c
diff -u src/usr.sbin/mopd/mopd/process.c:1.17 src/usr.sbin/mopd/mopd/process.c:1.18
--- src/usr.sbin/mopd/mopd/process.c:1.17	Tue Nov 17 18:58:07 2009
+++ src/usr.sbin/mopd/mopd/process.c	Tue May 24 13:08:17 2011
@@ -1,4 +1,4 @@
-/*	$NetBSD: process.c,v 1.17 2009/11/17 18:58:07 drochner Exp $	*/
+/*	$NetBSD: process.c,v 1.18 2011/05/24 13:08:17 joerg Exp $	*/
 
 /*
  * Copyright (c) 1993-95 Mats O Jansson.  All rights reserved.
@@ -26,7 +26,7 @@
 
 #include <sys/cdefs.h>
 #ifndef lint
-__RCSID("$NetBSD: process.c,v 1.17 2009/11/17 18:58:07 drochner Exp $");
+__RCSID("$NetBSD: process.c,v 1.18 2011/05/24 13:08:17 joerg Exp $");
 #endif
 
 #include "os.h"
@@ -182,16 +182,16 @@
 	mopPutLength(pkt, trans, idx);
 	newlen = mopGetLength(pkt, trans);
 
-	if ((DebugFlag == DEBUG_ONELINE)) {
+	if (DebugFlag == DEBUG_ONELINE) {
 		mopPrintOneline(stdout, pkt, trans);
 	}
 
-	if ((DebugFlag >= DEBUG_HEADER)) {
+	if (DebugFlag >= DEBUG_HEADER) {
 		mopPrintHeader(stdout, pkt, trans);
 		mopPrintMopHeader(stdout, pkt, trans);
 	}
 	
-	if ((DebugFlag >= DEBUG_INFO)) {
+	if (DebugFlag >= DEBUG_INFO) {
 		mopDumpDL(stdout, pkt, trans);
 	}
 
@@ -287,16 +287,16 @@
 	mopPutLength(pkt, trans, idx);
 	newlen = mopGetLength(pkt, trans);
 
-	if ((DebugFlag == DEBUG_ONELINE)) {
+	if (DebugFlag == DEBUG_ONELINE) {
 		mopPrintOneline(stdout, pkt, trans);
 	}
 
-	if ((DebugFlag >= DEBUG_HEADER)) {
+	if (DebugFlag >= DEBUG_HEADER) {
 		mopPrintHeader(stdout, pkt, trans);
 		mopPrintMopHeader(stdout, pkt, trans);
 	}
 	
-	if ((DebugFlag >= DEBUG_INFO)) {
+	if (DebugFlag >= DEBUG_INFO) {
 		mopDumpDL(stdout, pkt, trans);
 	}
 
@@ -337,7 +337,7 @@
 
 	dle = &dllist[slot];
 
-	if ((new_count == ((dle->count+1) % 256))) {
+	if (new_count == ((dle->count+1) % 256)) {
 		dle->loadaddr = dllist[slot].nloadaddr;
 		dle->count    = new_count;
 	} else if (new_count != (dle->count % 256)) {
@@ -406,16 +406,16 @@
 		}
 	}
 
-	if ((DebugFlag == DEBUG_ONELINE)) {
+	if (DebugFlag == DEBUG_ONELINE) {
 		mopPrintOneline(stdout, pkt, trans);
 	}
 
-	if ((DebugFlag >= DEBUG_HEADER)) {
+	if (DebugFlag >= DEBUG_HEADER) {
 		mopPrintHeader(stdout, pkt, trans);
 		mopPrintMopHeader(stdout, pkt, trans);
 	}
 	
-	if ((DebugFlag >= DEBUG_INFO)) {
+	if (DebugFlag >= DEBUG_INFO) {
 		mopDumpDL(stdout, pkt, trans);
 	}
 
@@ -439,16 +439,16 @@
 	struct dllist dl,*dl_rpr;
 	u_char  rpr_pgty,load;
 
-	if ((DebugFlag == DEBUG_ONELINE)) {
+	if (DebugFlag == DEBUG_ONELINE) {
 		mopPrintOneline(stdout, pkt, trans);
 	}
 
-	if ((DebugFlag >= DEBUG_HEADER)) {
+	if (DebugFlag >= DEBUG_HEADER) {
 		mopPrintHeader(stdout, pkt, trans);
 		mopPrintMopHeader(stdout, pkt, trans);
 	}
 	
-	if ((DebugFlag >= DEBUG_INFO)) {
+	if (DebugFlag >= DEBUG_INFO) {
 		mopDumpDL(stdout, pkt, trans);
 	}
 
@@ -573,16 +573,16 @@
 	u_char   mopcode;
 	struct dllist dl,*dl_rpr;
 
-	if ((DebugFlag == DEBUG_ONELINE)) {
+	if (DebugFlag == DEBUG_ONELINE) {
 		mopPrintOneline(stdout, pkt, trans);
 	}
 
-	if ((DebugFlag >= DEBUG_HEADER)) {
+	if (DebugFlag >= DEBUG_HEADER) {
 		mopPrintHeader(stdout, pkt, trans);
 		mopPrintMopHeader(stdout, pkt, trans);
 	}
 	
-	if ((DebugFlag >= DEBUG_INFO)) {
+	if (DebugFlag >= DEBUG_INFO) {
 		mopDumpRC(stdout, pkt, trans);
 	}
 

Reply via email to