Make kernel address arg of kvm_ckread() const void * so caller doesn't
need a cast. (approved by christos)
This commit is contained in:
parent
c50dc4c8fc
commit
85ed0bb278
@ -1,4 +1,4 @@
|
|||||||
/* $NetBSD: extern.h,v 1.28 2002/11/01 12:47:57 mrg Exp $ */
|
/* $NetBSD: extern.h,v 1.29 2003/01/20 18:24:03 dsl Exp $ */
|
||||||
|
|
||||||
/*-
|
/*-
|
||||||
* Copyright (c) 1991, 1993
|
* Copyright (c) 1991, 1993
|
||||||
@ -133,7 +133,7 @@ void ip_run(char *);
|
|||||||
void ip_time(char *);
|
void ip_time(char *);
|
||||||
void ip_zero(char *);
|
void ip_zero(char *);
|
||||||
int keyboard(void) __attribute__((__noreturn__));
|
int keyboard(void) __attribute__((__noreturn__));
|
||||||
ssize_t kvm_ckread(void *, void *, size_t);
|
ssize_t kvm_ckread(const void *, void *, size_t);
|
||||||
void labelbufcache(void);
|
void labelbufcache(void);
|
||||||
void labelicmp(void);
|
void labelicmp(void);
|
||||||
void labeliostat(void);
|
void labeliostat(void);
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $NetBSD: fetch.c,v 1.9 2000/12/01 02:19:43 simonb Exp $ */
|
/* $NetBSD: fetch.c,v 1.10 2003/01/20 18:24:03 dsl Exp $ */
|
||||||
|
|
||||||
/*-
|
/*-
|
||||||
* Copyright (c) 1980, 1992, 1993
|
* Copyright (c) 1980, 1992, 1993
|
||||||
@ -38,7 +38,7 @@
|
|||||||
#if 0
|
#if 0
|
||||||
static char sccsid[] = "@(#)fetch.c 8.1 (Berkeley) 6/6/93";
|
static char sccsid[] = "@(#)fetch.c 8.1 (Berkeley) 6/6/93";
|
||||||
#endif
|
#endif
|
||||||
__RCSID("$NetBSD: fetch.c,v 1.9 2000/12/01 02:19:43 simonb Exp $");
|
__RCSID("$NetBSD: fetch.c,v 1.10 2003/01/20 18:24:03 dsl Exp $");
|
||||||
#endif /* not lint */
|
#endif /* not lint */
|
||||||
|
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
@ -51,7 +51,7 @@ __RCSID("$NetBSD: fetch.c,v 1.9 2000/12/01 02:19:43 simonb Exp $");
|
|||||||
#include "extern.h"
|
#include "extern.h"
|
||||||
|
|
||||||
ssize_t
|
ssize_t
|
||||||
kvm_ckread(void *a, void *b, size_t l)
|
kvm_ckread(const void *a, void *b, size_t l)
|
||||||
{
|
{
|
||||||
if (kvm_read(kd, (u_long)a, b, l) != l) {
|
if (kvm_read(kd, (u_long)a, b, l) != l) {
|
||||||
if (verbose)
|
if (verbose)
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $NetBSD: vmstat.c,v 1.45 2003/01/18 21:18:18 christos Exp $ */
|
/* $NetBSD: vmstat.c,v 1.46 2003/01/20 18:24:03 dsl Exp $ */
|
||||||
|
|
||||||
/*-
|
/*-
|
||||||
* Copyright (c) 1983, 1989, 1992, 1993
|
* Copyright (c) 1983, 1989, 1992, 1993
|
||||||
@ -38,7 +38,7 @@
|
|||||||
#if 0
|
#if 0
|
||||||
static char sccsid[] = "@(#)vmstat.c 8.2 (Berkeley) 1/12/94";
|
static char sccsid[] = "@(#)vmstat.c 8.2 (Berkeley) 1/12/94";
|
||||||
#endif
|
#endif
|
||||||
__RCSID("$NetBSD: vmstat.c,v 1.45 2003/01/18 21:18:18 christos Exp $");
|
__RCSID("$NetBSD: vmstat.c,v 1.46 2003/01/20 18:24:03 dsl Exp $");
|
||||||
#endif /* not lint */
|
#endif /* not lint */
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@ -197,11 +197,9 @@ get_interrupt_events(void)
|
|||||||
ie->ie_name = malloc(evcnt.ev_namelen + 1);
|
ie->ie_name = malloc(evcnt.ev_namelen + 1);
|
||||||
if (ie->ie_group == NULL || ie->ie_name == NULL)
|
if (ie->ie_group == NULL || ie->ie_name == NULL)
|
||||||
return;
|
return;
|
||||||
if (!KREAD((char *)evcnt.ev_group, ie->ie_group,
|
if (!KREAD(evcnt.ev_group, ie->ie_group, evcnt.ev_grouplen + 1))
|
||||||
evcnt.ev_grouplen + 1))
|
|
||||||
return;
|
return;
|
||||||
if (!KREAD((char *)evcnt.ev_name, ie->ie_name,
|
if (!KREAD(evcnt.ev_name, ie->ie_name, evcnt.ev_namelen + 1))
|
||||||
evcnt.ev_namelen + 1))
|
|
||||||
return;
|
return;
|
||||||
ie->ie_count = &evptr->ev_count;
|
ie->ie_count = &evptr->ev_count;
|
||||||
ie->ie_loc = 0;
|
ie->ie_loc = 0;
|
||||||
|
Loading…
Reference in New Issue
Block a user