Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 772826 Details for
Bug 839900
app-shells/zsh-5.8.1-r1 is taking more than a minute for startup on slow filesystem
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch that fix the problem
0001-Revert-49792-Non-interative-shell-input-is-line-buff.patch (text/plain), 2.27 KB, created by
Klaus Ethgen
on 2022-04-22 07:48:09 UTC
(
hide
)
Description:
Patch that fix the problem
Filename:
MIME Type:
Creator:
Klaus Ethgen
Created:
2022-04-22 07:48:09 UTC
Size:
2.27 KB
patch
obsolete
>From e9a869627b1c7dd7e8024c07f3ed9ad10366f5e5 Mon Sep 17 00:00:00 2001 >From: Klaus Ethgen <Klaus@Ethgen.ch> >Date: Thu, 21 Apr 2022 15:07:59 +0100 >Subject: [PATCH] Revert "49792: Non-interative shell input is line buffered." > >This reverts commit dc5d41f93816f342bb2d33ffbdc30055cafcc4d9. >--- > ChangeLog | 5 ----- > Src/input.c | 21 +++++++-------------- > Test/A01grammar.ztst | 9 --------- > 3 files changed, 7 insertions(+), 28 deletions(-) > >diff --git a/ChangeLog b/ChangeLog >index cae2fc4e3..8a5ad4941 100644 >--- a/ChangeLog >+++ b/ChangeLog >@@ -1,8 +1,3 @@ >-2022-03-03 Peter Stephenson <p.w.stephenson@ntlworld.com> >- >- * 49792: Src/input.c, Test/A01grammar.ztst: Use line buffering >- for non-interactive input. >- > 2022-02-12 dana <dana@dana.is> > > * unposted: Config/version.mk, Etc/FAQ.yo, README: Update >diff --git a/Src/input.c b/Src/input.c >index caa8e23b0..18228b37d 100644 >--- a/Src/input.c >+++ b/Src/input.c >@@ -223,20 +223,13 @@ shingetchar(void) > return STOUC(*shinbufptr++); > > shinbufreset(); >- for (;;) { >- errno = 0; >- nread = read(SHIN, shinbufendptr, 1); >- if (nread > 0) { >- /* Use line buffering (POSIX requirement) */ >- if (*shinbufendptr++ == '\n') >- break; >- if (shinbufendptr == shinbuffer + SHINBUFSIZE) >- break; >- } else if (nread == 0 || errno != EINTR) >- break; >- } >- if (shinbufendptr == shinbuffer) >- return -1; >+ do { >+ errno = 0; >+ nread = read(SHIN, shinbuffer, SHINBUFSIZE); >+ } while (nread < 0 && errno == EINTR); >+ if (nread <= 0) >+ return -1; >+ shinbufendptr = shinbuffer + nread; > return STOUC(*shinbufptr++); > } > >diff --git a/Test/A01grammar.ztst b/Test/A01grammar.ztst >index adbf5f1d9..1e0e9a04e 100644 >--- a/Test/A01grammar.ztst >+++ b/Test/A01grammar.ztst >@@ -932,12 +932,3 @@ F:Note that the behaviour of 'exit' inside try-list inside a function is unspeci > $ZTST_testdir/../Src/zsh -fc '{ ( ) } always { echo foo }' > -f:exec last command optimization inhibited for try/always > >foo >- >- ( >- export VALUE=first >- print -l 'echo Value is $VALUE' 'VALUE=second sh' 'echo Value is $VALUE' | >- $ZTST_testdir/../Src/zsh -f >- ) >-0:Non-interactive shell command input is line buffered >->Value is first >->Value is second >-- >2.35.2 >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 839900
: 772826