diff options
| author | christos <christos@NetBSD.org> | 2020-05-02 18:42:30 +0000 |
|---|---|---|
| committer | christos <christos@NetBSD.org> | 2020-05-02 18:42:30 +0000 |
| commit | 74dc1aec84f9745f9e28923b9031dc5a3b0e0f62 (patch) | |
| tree | 16ac9251873ea6875efd1cde8c3283cd27b756ac /usr.bin/fstat | |
| parent | 6ef244da9cdc7a4c49e9d88422a3410aefe18aae (diff) | |
nuke random stuff that does not exist anymore.
Diffstat (limited to 'usr.bin/fstat')
| -rw-r--r-- | usr.bin/fstat/misc.c | 36 |
1 files changed, 4 insertions, 32 deletions
diff --git a/usr.bin/fstat/misc.c b/usr.bin/fstat/misc.c index 2248ac1063c..a4bebed7e92 100644 --- a/usr.bin/fstat/misc.c +++ b/usr.bin/fstat/misc.c @@ -1,4 +1,4 @@ -/* $NetBSD: misc.c,v 1.22 2019/09/06 17:08:22 christos Exp $ */ +/* $NetBSD: misc.c,v 1.23 2020/05/02 18:42:30 christos Exp $ */ /*- * Copyright (c) 2008 The NetBSD Foundation, Inc. @@ -30,7 +30,7 @@ */ #include <sys/cdefs.h> -__RCSID("$NetBSD: misc.c,v 1.22 2019/09/06 17:08:22 christos Exp $"); +__RCSID("$NetBSD: misc.c,v 1.23 2020/05/02 18:42:30 christos Exp $"); #include <stdbool.h> #include <sys/param.h> @@ -207,35 +207,6 @@ p_mqueue(struct file *f) } static int -p_rnd(struct file *f) -{ - struct cprng_strong { - char cs_name[16]; - int cs_flags; - /*...*/ - } str; - struct rnd_ctx { - struct cprng_strong *rc_cprng; - bool rc_hard; - } ctx; - char buf[1024]; - - if (!KVM_READ(f->f_data, &ctx, sizeof(ctx))) { - dprintf("can't read rnd_ctx at %p for pid %d", f->f_data, Pid); - return 0; - } - if (!KVM_READ(ctx.rc_cprng, &str, sizeof(str))) { - dprintf("can't read cprng_strong at %p for pid %d", f->f_data,\ - Pid); - return 0; - } - snprintb(buf, sizeof(buf), CPRNG_FMT, str.cs_flags); - (void)printf("* rnd \"%s\" flags %s", str.cs_name, buf); - oprint(f, "\n"); - return 0; -} - -static int p_kqueue(struct file *f) { struct kqueue kq; @@ -281,7 +252,8 @@ pmisc(struct file *f, const char *name) case NL_KQUEUE: return p_kqueue(f); case NL_RND: - return p_rnd(f); + printf("* random %p", f->f_data); + break; case NL_SEM: return p_sem(f); case NL_TAP: |
