Date: Mon, 3 Aug 1998 11:49:58 +0200 (CEST) From: Stefan Eggers <seggers@semyam.dinoco.de> To: FreeBSD-gnats-submit@FreeBSD.ORG Cc: seggers@semyam.dinoco.de Subject: kern/7482: nonsense-code in kern_subr.c Message-ID: <199808030949.LAA08621@semyam.dinoco.de>
next in thread | raw e-mail | index | archive | help
>Number: 7482
>Category: kern
>Synopsis: nonsense-code in kern_subr.c
>Confidential: no
>Severity: non-critical
>Priority: low
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: change-request
>Submitter-Id: current-users
>Arrival-Date: Mon Aug 3 07:20:00 PDT 1998
>Last-Modified:
>Originator: Stefan Eggers
>Organization:
none
>Release: FreeBSD 3.0-CURRENT i386
>Environment:
-current cvsup'ed last Friday.
>Description:
Look at the code from kern/kern_subr.c below. It sets cnt to
the value of tcnt when they differ. If they don't differ this is a
noop.
This can be simplified like you see in the patch. Makes this
code easier to read.
>How-To-Repeat:
N/A
>Fix:
--- kern_subr.c.ORIG Sun Jul 19 11:37:57 1998
+++ kern_subr.c Mon Aug 3 11:46:09 1998
@@ -224,9 +224,7 @@
break;
tcnt = npagesmoved * PAGE_SIZE;
- if (tcnt != cnt) {
- cnt = tcnt;
- }
+ cnt = tcnt;
if (error)
break;
>Audit-Trail:
>Unformatted:
To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-bugs" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199808030949.LAA08621>
