diff options
author | John Levon <john.levon@joyent.com> | 2019-09-12 20:26:08 +0000 |
---|---|---|
committer | John Levon <john.levon@joyent.com> | 2019-09-12 20:26:08 +0000 |
commit | c6dd2307128aa25ac346f7818440cd5cfd1f7221 (patch) | |
tree | 9bda47db825ca7697580de5510764735b0748431 /usr/src/uts/common/contract | |
parent | 1cc6f4c0fcc857bd86b9a8234d9ff75d5a6b9384 (diff) | |
download | illumos-joyent-c6dd2307128aa25ac346f7818440cd5cfd1f7221.tar.gz |
OS-7931 ::refstr would be useful
OS-7932 ::ps -s could show service FMRIs
OS-7934 ptree could show service FMRIs
OS-3513 ptools should see more process arguments
Reviewed by: Jerry Jelinek <jerry.jelinek@joyent.com>
Reviewed by: Jason King <jason.king@joyent.com>
Approved by: Jerry Jelinek <jerry.jelinek@joyent.com>
Diffstat (limited to 'usr/src/uts/common/contract')
-rw-r--r-- | usr/src/uts/common/contract/process.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/usr/src/uts/common/contract/process.c b/usr/src/uts/common/contract/process.c index e46cbd3abf..6e43bd7aef 100644 --- a/usr/src/uts/common/contract/process.c +++ b/usr/src/uts/common/contract/process.c @@ -21,7 +21,7 @@ /* * Copyright 2009 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. - * Copyright 2016 Joyent, Inc. + * Copyright 2019 Joyent, Inc. */ #include <sys/mutex.h> @@ -737,13 +737,11 @@ contract_process_status(contract_t *ct, zone_t *zone, int detail, nvlist_t *nvl, * if we are in a local zone and svc_fmri was inherited from * the global zone, we provide fake svc_fmri and svc_ctid */ - if (local_svc_zone_enter == 0|| + if (local_svc_zone_enter == 0 || zone->zone_uniqid == GLOBAL_ZONEUNIQID) { if (detail > CTD_COMMON) { VERIFY(nvlist_add_int32(nvl, CTPS_SVC_CTID, ctp->conp_svc_ctid) == 0); - } - if (detail == CTD_ALL) { VERIFY(nvlist_add_string(nvl, CTPS_SVC_FMRI, refstr_value(ctp->conp_svc_fmri)) == 0); } @@ -751,8 +749,6 @@ contract_process_status(contract_t *ct, zone_t *zone, int detail, nvlist_t *nvl, if (detail > CTD_COMMON) { VERIFY(nvlist_add_int32(nvl, CTPS_SVC_CTID, local_svc_zone_enter) == 0); - } - if (detail == CTD_ALL) { VERIFY(nvlist_add_string(nvl, CTPS_SVC_FMRI, CT_PR_SVC_FMRI_ZONE_ENTER) == 0); } |