nfsstat.c (261514) | nfsstat.c (281691) |
---|---|
1/* 2 * Copyright (c) 1983, 1989, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * This code is derived from software contributed to Berkeley by 6 * Rick Macklem at The University of Guelph. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 27 unchanged lines hidden (view full) --- 36 The Regents of the University of California. All rights reserved.\n"; 37#endif /* not lint */ 38 39#ifndef lint 40#if 0 41static char sccsid[] = "@(#)nfsstat.c 8.2 (Berkeley) 3/31/95"; 42#endif 43static const char rcsid[] = | 1/* 2 * Copyright (c) 1983, 1989, 1993 3 * The Regents of the University of California. All rights reserved. 4 * 5 * This code is derived from software contributed to Berkeley by 6 * Rick Macklem at The University of Guelph. 7 * 8 * Redistribution and use in source and binary forms, with or without --- 27 unchanged lines hidden (view full) --- 36 The Regents of the University of California. All rights reserved.\n"; 37#endif /* not lint */ 38 39#ifndef lint 40#if 0 41static char sccsid[] = "@(#)nfsstat.c 8.2 (Berkeley) 3/31/95"; 42#endif 43static const char rcsid[] = |
44 "$FreeBSD: head/usr.bin/nfsstat/nfsstat.c 261514 2014-02-05 14:44:59Z jhb $"; | 44 "$FreeBSD: head/usr.bin/nfsstat/nfsstat.c 281691 2015-04-18 16:08:06Z trasz $"; |
45#endif /* not lint */ 46 47#include <sys/param.h> 48#include <sys/module.h> 49#include <sys/mount.h> 50#include <sys/time.h> 51#include <sys/sysctl.h> 52#include <nfs/nfsproto.h> --- 187 unchanged lines hidden (view full) --- 240 if (*srvstp != NULL && kvm_read(kd, 241 (u_long)nl[N_NFSRVSTAT].n_value, *srvstp, 242 sizeof(struct nfsrvstats)) < 0) { 243 *srvstp = NULL; 244 } 245 } else { 246 if (zero) 247 bzero(&zerostat, sizeof(zerostat)); | 45#endif /* not lint */ 46 47#include <sys/param.h> 48#include <sys/module.h> 49#include <sys/mount.h> 50#include <sys/time.h> 51#include <sys/sysctl.h> 52#include <nfs/nfsproto.h> --- 187 unchanged lines hidden (view full) --- 240 if (*srvstp != NULL && kvm_read(kd, 241 (u_long)nl[N_NFSRVSTAT].n_value, *srvstp, 242 sizeof(struct nfsrvstats)) < 0) { 243 *srvstp = NULL; 244 } 245 } else { 246 if (zero) 247 bzero(&zerostat, sizeof(zerostat)); |
248 buflen = sizeof(struct nfsstats); 249 if (*stp != NULL && sysctlbyname("vfs.oldnfs.nfsstats", *stp, 250 &buflen, zero ? &zerostat : NULL, zero ? buflen : 0) < 0) { 251 if (errno != ENOENT) 252 err(1, "sysctl: vfs.oldnfs.nfsstats"); 253 *stp = NULL; 254 } | |
255 buflen = sizeof(struct nfsrvstats); 256 if (*srvstp != NULL && sysctlbyname("vfs.nfsrv.nfsrvstats", 257 *srvstp, &buflen, zero ? &zerostat : NULL, 258 zero ? buflen : 0) < 0) { 259 if (errno != ENOENT) 260 err(1, "sysctl: vfs.nfsrv.nfsrvstats"); 261 *srvstp = NULL; 262 } --- 783 unchanged lines hidden --- | 248 buflen = sizeof(struct nfsrvstats); 249 if (*srvstp != NULL && sysctlbyname("vfs.nfsrv.nfsrvstats", 250 *srvstp, &buflen, zero ? &zerostat : NULL, 251 zero ? buflen : 0) < 0) { 252 if (errno != ENOENT) 253 err(1, "sysctl: vfs.nfsrv.nfsrvstats"); 254 *srvstp = NULL; 255 } --- 783 unchanged lines hidden --- |