diff options
| author | Mikael Magnusson <mikachu@gmail.com> | 2026-06-11 06:34:30 +0200 |
|---|---|---|
| committer | Mikael Magnusson <mikachu@gmail.com> | 2026-06-14 01:57:17 +0200 |
| commit | 807eac8dff2b2281ac7cf52ebd8c7b73fa358e37 (patch) | |
| tree | 858330ac32855f43f046c320b175ab63e691fec8 | |
| parent | 54751: make the W02 test not take a full minute on linux (diff) | |
| download | zsh-807eac8dff2b2281ac7cf52ebd8c7b73fa358e37.tar zsh-807eac8dff2b2281ac7cf52ebd8c7b73fa358e37.tar.gz zsh-807eac8dff2b2281ac7cf52ebd8c7b73fa358e37.tar.bz2 zsh-807eac8dff2b2281ac7cf52ebd8c7b73fa358e37.tar.lz zsh-807eac8dff2b2281ac7cf52ebd8c7b73fa358e37.tar.xz zsh-807eac8dff2b2281ac7cf52ebd8c7b73fa358e37.tar.zst zsh-807eac8dff2b2281ac7cf52ebd8c7b73fa358e37.zip | |
54753: zpty: register pty fd as FDT_MODULE so it isn't closed when forking
This lets us remove these mysterious braces too.
| -rw-r--r-- | ChangeLog | 3 | ||||
| -rw-r--r-- | Src/Modules/zpty.c | 3 | ||||
| -rw-r--r-- | Test/W02jobs.ztst | 3 |
3 files changed, 5 insertions, 4 deletions
@@ -1,5 +1,8 @@ 2026-06-14 Mikael Magnusson <mikachu@gmail.com> + * 54753: Src/Modules/zpty.c, Test/W02jobs.ztst: zpty: register + pty fd as FDT_MODULE so it isn't closed when forking + * 54751: Test/W02jobs.ztst: make the W02 test not take a full minute on linux diff --git a/Src/Modules/zpty.c b/Src/Modules/zpty.c index 5f3a8f24e..6e201e76b 100644 --- a/Src/Modules/zpty.c +++ b/Src/Modules/zpty.c @@ -447,9 +447,8 @@ newptycmd(char *nam, char *pname, char **args, int echo, int nblock) return 1; } } -#else - addmodulefd(master, FDT_INTERNAL); #endif + addmodulefd(master, FDT_MODULE); p = (Ptycmd) zalloc(sizeof(*p)); diff --git a/Test/W02jobs.ztst b/Test/W02jobs.ztst index d92885364..bfbb02f7b 100644 --- a/Test/W02jobs.ztst +++ b/Test/W02jobs.ztst @@ -23,8 +23,7 @@ zpty_stop() { # exit twice in case of check_jobs zpty -w zsh $'exit\nexit\n' - # zpty gives no output when piped without these braces (?) - { zpty -r zsh } | sed $'/[^[:space:]]/!d; s/\r$//;' + zpty -r zsh | sed $'/[^[:space:]]/!d; s/\r$//;' zpty -d : } |
