summaryrefslogtreecommitdiff
path: root/usr/src/cmd/stat/kstat
diff options
context:
space:
mode:
authorBryan Cantrill <bryan@joyent.com>2013-06-13 19:58:31 +0000
committerRobert Mustacchi <rm@joyent.com>2013-08-05 07:57:40 -0700
commit9736aecd323ba323a24c159dc877b29795d68a0a (patch)
tree0c524fa29d135a55f0542a66b5dd5c0aca6a4acd /usr/src/cmd/stat/kstat
parentea2603507f6302005d1c10815c4f0458ae3ec803 (diff)
downloadillumos-gate-9736aecd323ba323a24c159dc877b29795d68a0a.tar.gz
3988 kstat(1) woefully inefficient on fully specified kstats
Reviewed by: Robert Mustacchi <rm@joyent.com> Approved by: Gordon Ross <gwr@nexenta.com>
Diffstat (limited to 'usr/src/cmd/stat/kstat')
-rw-r--r--usr/src/cmd/stat/kstat/kstat.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/usr/src/cmd/stat/kstat/kstat.c b/usr/src/cmd/stat/kstat/kstat.c
index 2ce62fc037..ee95db1c64 100644
--- a/usr/src/cmd/stat/kstat/kstat.c
+++ b/usr/src/cmd/stat/kstat/kstat.c
@@ -23,6 +23,7 @@
* Copyright (c) 1999, 2010, Oracle and/or its affiliates. All rights reserved.
* Copyright (c) 2013 David Hoeppner. All rights reserved.
* Copyright 2013 Nexenta Systems, Inc. All rights reserved.
+ * Copyright (c) 2013, Joyent, Inc. All rights reserved.
*/
/*
@@ -621,7 +622,7 @@ ks_instances_read(kstat_ctl_t *kc)
skip = B_TRUE;
selector = list_head(&selector_list);
while (selector != NULL) {
- if (ks_match(kp->ks_module, &selector->ks_module) ||
+ if (ks_match(kp->ks_module, &selector->ks_module) &&
ks_match(kp->ks_name, &selector->ks_name)) {
skip = B_FALSE;
break;