about summary refs log tree commit diff
path: root/Src/Modules/system.c
diff options
context:
space:
mode:
authorPeter Stephenson <p.stephenson@samsung.com>2018-06-15 15:02:36 +0100
committerPeter Stephenson <p.stephenson@samsung.com>2018-06-15 15:02:36 +0100
commit9408c4825b339c43299a39b46811fc6153740e01 (patch)
treeb1f4e68fda0b1cf3a1f18da06d4377d36ce2fd6d /Src/Modules/system.c
parentf37c181b29149c6829cc8a86f7348335a08d9670 (diff)
downloadzsh-9408c4825b339c43299a39b46811fc6153740e01.tar.gz
zsh-9408c4825b339c43299a39b46811fc6153740e01.tar.xz
zsh-9408c4825b339c43299a39b46811fc6153740e01.zip
users/23472: Add $sysparams[procsubstpid] to zsh/system
Diffstat (limited to 'Src/Modules/system.c')
-rw-r--r--Src/Modules/system.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/Src/Modules/system.c b/Src/Modules/system.c
index 9fd4d2583..7a4f4ee13 100644
--- a/Src/Modules/system.c
+++ b/Src/Modules/system.c
@@ -772,6 +772,8 @@ fillpmsysparams(Param pm, const char *name)
 	num = (int)getpid();
     } else if (!strcmp(name, "ppid")) {
 	num = (int)getppid();
+    } else if (!strcmp(name, "procsubstpid")) {
+	num = (int)procsubstpid;
     } else {
 	pm->u.str = dupstring("");
 	pm->node.flags |= PM_UNSET;
@@ -805,6 +807,8 @@ scanpmsysparams(UNUSED(HashTable ht), ScanFunc func, int flags)
     func(&spm.node, flags);
     fillpmsysparams(&spm, "ppid");
     func(&spm.node, flags);
+    fillpmsysparams(&spm, "procsubstpid");
+    func(&spm.node, flags);
 }
 
 static struct mathfunc mftab[] = {