summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorHans-Joerg Hoexer <hshoexer@cvs.openbsd.org>2005-05-03 11:10:57 +0000
committerHans-Joerg Hoexer <hshoexer@cvs.openbsd.org>2005-05-03 11:10:57 +0000
commitc78c3a0f23b2e6d5b96c37420505688aaf534739 (patch)
tree7d08cf6d87b1747fb504330ed75667783b6c847b /sys
parentaeb041f01654f9bbafc2ca9b9f3297b09404ace7 (diff)
clean up some small fallout from initial freebsd import.
ok grange@
Diffstat (limited to 'sys')
-rw-r--r--sys/kern/kern_tc.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/kern/kern_tc.c b/sys/kern/kern_tc.c
index 4b9a17b1db1..52094aa620c 100644
--- a/sys/kern/kern_tc.c
+++ b/sys/kern/kern_tc.c
@@ -6,7 +6,7 @@
* this stuff is worth it, you can buy me a beer in return. Poul-Henning Kamp
* ----------------------------------------------------------------------------
*
- * $OpenBSD: kern_tc.c,v 1.4 2005/04/21 00:20:13 deraadt Exp $
+ * $OpenBSD: kern_tc.c,v 1.5 2005/05/03 11:10:56 hshoexer Exp $
* $FreeBSD: src/sys/kern/kern_tc.c,v 1.148 2003/03/18 08:45:23 phk Exp $
*/
@@ -500,14 +500,13 @@ sysctl_tc_choice(void *oldp, size_t *oldlenp, void *newp, size_t newlen)
maxlen += sizeof(buf);
choices = malloc(maxlen, M_TEMP, M_WAITOK);
*choices = '\0';
- for (tc = timecounters; error == 0 && tc != NULL; tc = tc->tc_next) {
+ for (tc = timecounters; tc != NULL; tc = tc->tc_next) {
snprintf(buf, sizeof(buf), "%s%s(%d)",
spc, tc->tc_name, tc->tc_quality);
spc = " ";
strlcat(choices, buf, maxlen);
}
- if (!error)
- error = sysctl_rdstring(oldp, oldlenp, newp, choices);
+ error = sysctl_rdstring(oldp, oldlenp, newp, choices);
free(choices, M_TEMP);
return (error);
}