On Wed, Feb 10, 2021 at 07:30:17PM +0400, Vladimir N. Oleynik wrote:
>
> But I do not show this patch in
> https://git.kernel.org/pub/scm/utils/dash/dash.git/
> Its ok?
It's still in the review process:
https://patchwork.kernel.org/project/dash/list/
Thanks,
--
Email: Herb
} else if (c != '}') {
>int cc = c;
I would rather test against VSNORMAL.
Fixes: 7710a926b321 ("parser: Only accept single-digit parameter...")
Reported-by: Vladimir N. Oleynik
Signed-off-by: Herbert Xu
diff --git a/src/p
es painful when it is expanded
> over and over and does anything non-trivial, even just a command
> substitution that runs no external commands.
OK, in that case I think it's best to fix this in libedit instead.
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~her
C. McEnroe wrote:
> Previously, configure --with-libedit would only fail in the case where
> libedit is available but its header file histedit.h is not.
> ---
> configure.ac | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
Patch applied. Thanks.
--
Email: Herbert Xu
actually wanted the prompt to change?
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Fri, Jan 08, 2021 at 08:55:41PM +, Harald van Dijk wrote:
> On 18/05/2018 19:39, Herbert Xu wrote:
> > This patch adds basic vfork support for the case of a simple command.
> > ... @@ -879,17 +892,30 @@ forkchild(struct job *jp, union node *
ts status
through patchwork at:
https://patchwork.kernel.org/project/dash/list/
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
;t find the
commit though because it appears to be there:
https://git.kernel.org/pub/scm/utils/dash/dash.git/commit/?id=6359d7aa739b9f02f622805f4dbddeaf0ae61981
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
anks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
by default.
I think the approach of blocking all signals should be able to
resolve this too if anyone cares enough about this case.
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
this is by not trying to make the shell start a new
> process group, or at least not make it the foreground process group.
> Most other shells appear to not try to do this.
This patch implements the blocking of SIGTTOU (and everything else)
while we call tcsetpgrp.
Reported-by: Steffen Nurpmes
ess they have all
removed this option I'm not going to change it.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
to pungetc")
Reported-by: Denys Vlasenko
Signed-off-by: Herbert Xu
diff --git a/src/input.c b/src/input.c
index 4987732..d7c101b 100644
--- a/src/input.c
+++ b/src/input.c
@@ -87,6 +87,7 @@ INIT {
RESET {
/* clear input buffer */
basepf.lleft = basepf.nleft = 0;
+ ba
On Thu, Dec 10, 2020 at 10:20:29AM -0500, Jeff King wrote:
>
> It seems like it happens for "foo/", too. If I compile:
I think the key is that dash uses GLOB_NOMAGIC.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana
ot;foo". This should return no match.
If you change the pattern to "foo/", then it also matches but
returns with the string "foo/" as expected.
The only flag we pass to glob(3) is GLOB_NOMAGIC.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
the problem doesn't occur for "foo/".
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
pana.org.au/
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
f that child. Since the
child was killed, we need to ignore that, so this works for me:
wait $MONPID 2> /dev/null || :
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Only clear gotsigchld when waiting...")
Reported-by: Michael Biebl
Signed-off-by: Herbert Xu
diff --git a/src/jobs.c b/src/jobs.c
index 3417633..516786f 100644
--- a/src/jobs.c
+++ b/src/jobs.c
@@ -81,6 +81,7 @@
#define DOWAIT_NONBLOCK 0
#define DOWAIT_BLOCK 1
#define DOWAIT_WAITCMD
ndeed
a change in behaviour which is undesirable.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
f the bash script
rather than bash itself.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Tue, Dec 01, 2020 at 10:55:06AM +, Harald van Dijk wrote:
>
> You wrote: "So the problem is really in the parent of this shell, which
> appears to be bash:"
You should read my follow-up email too that suggested changing
the systemd script.
Cheers,
--
Email: Herbert
are no other children around that you don't know of.
In the original bug, the proper solution is to wait on the PID
that the script just sent a kill signal to.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
for the last command in a list when it can just
> exec() without a fork() instead. A minimal example without an explicit exec
> is
>
> bash -c 'dash -c ": & wait" <(sleep 1d)'
I'm not sure about that because bash itself is still hanging around,
if it were really the -c optimisation then bash should not appear in
the ps output at all.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Tue, Dec 01, 2020 at 05:06:18PM +1100, Herbert Xu wrote:
>
> For some reason this is causing the final two tee's to be created
> as children of debian/tests/timedated rather than the bash shell.
An alternative to changing the parent is of course to do
wait $MONP
On Tue, Dec 01, 2020 at 04:42:03PM +1100, Herbert Xu wrote:
>
> Nevermind, I see that the script has been modified to use bash.
>
> I can reproduce the problem now so it's all good.
OK the problem is this:
sh -c 'sleep 1d& exec $MYSHELL -c "sleep 1& w
On Tue, Dec 01, 2020 at 04:38:37PM +1100, Herbert Xu wrote:
>
> FWIW I'm unable to reproduce it with autopkgtest. This is what
> I get:
>
> root@test0:~# autopkgtest --test-name=timedated systemd-246.6/ -B -- lxc -s
> autopkgtest-sid
> autopkgtest [16:32:45]:
PASS
autopkgtest [16:33:32]: summary
timedatedPASS
root@test0:~#
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
Andrej Shadura wrote:
>
> this is another bug report I have received.
This is a bug in glob(3). Please dup and reassign to libc6. There
is a patch in the queue to disable glob by default again.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key
reproduce it, could you please run the offending script
under strace -f and send me the result? That should pin-point the
problem.
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Mon, Nov 16, 2020 at 01:47:48PM +1100, Herbert Xu wrote:
> René Scharfe wrote:
> >
> > on Debian testing dash eats trailing slashes of parameters that happen
> > to be regular files when expanding "$@". Example:
> >
> > $ rm -f foo bar
az foo/ bar/ ./
> baz foo bar/ ./
In fact you just have to do
dash -c 'echo bar\/'
This is a bug in glob(3). It's stripping the slash.
I guess we'll just have to disable glob again.
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
ar build
failures.
Reported-by: Martijn Dekker
Signed-off-by: Herbert Xu
diff --git a/configure.ac b/configure.ac
index 955e2bb..ab3c02e 100644
--- a/configure.ac
+++ b/configure.ac
@@ -145,10 +145,6 @@ AC_CHECK_FUNC(stat64,, [
AC_DEFINE(fstat64, fstat, [64-bit operations are the sam
c: ./src/dash.1:2330:6: STYLE: referenced manual not found: Xr csh 1
>
> Signed-off-by: Bjarni Ingi Gislason
> ---
> src/bltin/echo.1 | 6 +++--
> src/bltin/printf.1 | 13 ++-
> src/bltin/test.1 | 2 +-
> src/dash.1 | 57 +++---
> 4 files changed, 45 insertions(+), 33 deletions(-)
Patch applied. Thanks.
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
] https://www.spinics.net/lists/dash/msg01888.html
AFAIK nobody has actually posted a patch to this list.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
./../src/trap.c ../../src/output.c ../../src/bltin/printf.c
../../src/system.c ../../src/bltin/test.c ../../src/bltin/times.c
../../src/var.c
I'm not cross-compiling though.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
This patch moves the nflag check from cmdloop into evaltree. This
is so that nflag will be in force even if we enter the shell via a
path other than cmdloop, e.g., through sh -c.
Reported-by: Joey Hess
Signed-off-by: Herbert Xu
diff --git a/src/eval.c b/src/eval.c
index d10be38..9476fbb
somewhere and interferes with the next
> command to be read.
This is because dash needs to clear the unget buffer on reset.
Reported-by: Matt Whitlock
Fixes: 17db43b58415 ("input: Allow two consecutive calls to pungetc")
Signed-off-by: Herbert Xu
diff --git a/src/input.c b/src/
("jobs: Only clear gotsigchld when waiting...")
Signed-off-by: Herbert Xu
diff --git a/src/jobs.c b/src/jobs.c
index 94bf47e..3417633 100644
--- a/src/jobs.c
+++ b/src/jobs.c
@@ -1135,7 +1135,6 @@ static int dowait(int block, struct job *jp)
rpid = 1;
The USE_NORETURN was added because gcc was buggy almost 20 years
ago. This is no longer needed and this patch removes it.
Signed-off-by: Herbert Xu
diff --git a/src/error.h b/src/error.h
index 94e30a2..661a8a0 100644
--- a/src/error.h
+++ b/src/error.h
@@ -116,11 +116,7 @@ void __inton(void
ll be uninterruptible.
Signed-off-by: Herbert Xu
diff --git a/configure.ac b/configure.ac
index ce5feec..955e2bb 100644
--- a/configure.ac
+++ b/configure.ac
@@ -151,6 +151,13 @@ AC_CHECK_FUNC(stat64,, [
[64-bit operations are the same as 32-bit])
])
+AC_CHECK_FUNC(g
As fnmatch(3) and glob(3) from glibc are now working consistently,
this patch enables them by default.
Signed-off-by: Herbert Xu
diff --git a/configure.ac b/configure.ac
index dbd97d8..d73b2bf 100644
--- a/configure.ac
+++ b/configure.ac
@@ -37,9 +37,10 @@ if test "$enable_static" = &
Martin Michlmayr wrote:
> Signed-off-by: Martin Michlmayr
Patch applied. Thanks.
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
retry the open64 call if
necessary. It also calls sh_error when appropriate.
Fixes: 3800d4934391 ("[JOBS] Fix dowait signal race")
Reported-by: Samuel Thibault
Signed-off-by: Herbert Xu
diff --git a/src/input.c b/src/input.c
index 17544e7..6103312 100644
--- a/src/input.c
+++ b/s
$$] echo done
> done
>
> - dash: (stalls it set -x)
>
> /tmp > dash test.sh
> +export PS4=+ $(date +%T.%N) [$$]
> ^C^C
This patch fixes the infinite loop caused by repeated expansions
of PS4.
Reported-by: Yaroslav Halchenko
Signed-off-by: Herbert Xu
diff --
stead delays the marking of aliases
until the second pgetc. This has the same effect as the current
PEOA code while keeping the complexities within the input code.
Signed-off-by: Herbert Xu
diff --git a/src/input.c b/src/input.c
index 17544e7..cf4efdc 100644
--- a/src/input.c
+++ b/src/input.c
@@
ollowed by a new-line.
This patch fixes it by calling pgetc.
Reported-by: Matt Whitlock
Fixes: 6bbc71d84bea ("parser: use pgetc_eatbnl() in more places")
Signed-off-by: Herbert Xu
diff --git a/src/parser.c b/src/parser.c
index 3131045..03c103b 100644
--- a/src/parser.c
+++ b/src/parse
than one started by
a signal like SIGINT.
Reported-by: Harald van Dijk
Signed-off-by: Herbert Xu
diff --git a/src/parser.c b/src/parser.c
index 3131045..54c2861 100644
--- a/src/parser.c
+++ b/src/parser.c
@@ -1565,10 +1565,11 @@ setprompt(int which)
const char *
expandstr(const char *
,
> default to /tmp.
>
> The mkbuiltins script was already hardened to work relative to TMPDIR,
> also defaulting to /tmp.
>
> v2 ensures that TMPDIR is quoted.
> v3 adds an extra quotation that prevents extra pathname expansions.
>
> Signed-off-by: Michael Greenberg
Patc
move the definition as it is not needed.
>
> Signed-off-by: Jeroen Roovers
> Signed-off-by: Mike Gilbert
> ---
> src/input.c | 4
> 1 file changed, 4 deletions(-)
Patch applied. Thanks.
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Wed, Apr 29, 2020 at 08:29:53AM +0200, Denys Vlasenko wrote:
> Signed-off-by: Denys Vlasenko
> ---
> src/expand.c | 10 --
> 1 file changed, 4 insertions(+), 6 deletions(-)
Patch applied. Thanks.
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
P
There are some remaining stat/readdir calls in dash that may lead
to spurious EOVERFLOW errors on 32-bit platforms. This patch changes
them (as well as open(2)) to use the explicit large file API.
Reported-by: Tatsuki Sugiura
Signed-off-by: Herbert Xu
diff --git a/configure.ac b/configure.ac
wise it could result in
unnecessary pattern expansion (e.g., someone does TMPDIR=/*/*/*).
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Wed, Feb 19, 2020 at 05:39:13PM +0100, Denys Vlasenko wrote:
> Signed-off-by: Denys Vlasenko
> ---
> src/var.c | 24
> src/var.h | 1 -
> 2 files changed, 4 insertions(+), 21 deletions(-)
Patch applied. Thanks.
--
Email: Herbert Xu
On Wed, Feb 19, 2020 at 11:30:08AM +0100, Denys Vlasenko wrote:
> To make it clearer what it is doing: nonblocking wait()
>
> Signed-off-by: Denys Vlasenko
> ---
> src/jobs.c | 8
> 1 file changed, 4 insertions(+), 4 deletions(-)
Patch applied. Thanks.
--
Email
,
> default to /tmp.
>
> The mkbuiltins script was already hardened to work relative to TMPDIR,
> also defaulting to /tmp.
>
> Signed-off-by: Michael Greenberg
Please make sure TMPDIR is quoted.
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP
hen it should, dash currently gets
it wrong in every case.
This patch fixes it by saving checkkwd and zeroing it where needed.
Suggested-by: Harald van Dijk
Reported-by: Harald van Dijk
Reported-by: Martijn Dekker
Signed-off-by: Herbert Xu
diff --git a/src/parser.c b/src/parser.c
index 5c9e9a
ust wrong.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
se? Should I resubmit the patch?
It means that the patch in question has been superseded by another
one, namely:
https://patchwork.kernel.org/patch/10263979/
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
> again. I guess it just got lost?
How about a resend?
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
bash ./test.sh one two three four five six seven eight nine ten
> one0
This patch should fix the problem.
Signed-off-by: Herbert Xu
diff --git a/src/parser.c b/src/parser.c
index 1f9e8ec..2f14bf3 100644
--- a/src/parser.c
+++ b/src/parser.c
@@ -1268,7 +1268,7 @@ varname:
9 in openhere
> ==39623==ABORTING
>
> This bug can be reproduced by running "dash < min" where min is þhe file
> attached. I was able to reproduce this bug with the current git version
> and the current debian version.
>
> cheers
> project-repo
>
> < `&l
On Fri, Jun 22, 2018 at 10:41:43PM +0800, Herbert Xu wrote:
> Benedikt Becker wrote:
> > Hi,
> >
> > Dash does not ignore the -e option in substitutions $(...) under AND/OR
> > lists and conditions. For example, in the program
> >
> > set -e
> >
and. This patch fixes it by resetting the handler
when entering a subshell.
Reported-by: Martijn Dekker
Signed-off-by: Herbert Xu
diff --git a/src/eval.c b/src/eval.c
index 1aad31a..6ee2e1a 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -41,6 +41,7 @@
* Evaluate a command.
*/
+#include "
foobar ) && echo WOOPS
> > EOF
> src/dash: 1: set: Illegal option -o foobar
> $ echo end
> end
> $
> WOOPS
> $
>
> This was introduced by
>
> commit 46d5a7fcea81b489819f753451c1ad2fe435f148
> Author: Herbert Xu
> Date: Tue Mar
n Dekker
Fixes: 3cd538634f71 ("expand: Do not reprocess data when...")
Signed-off-by: Herbert Xu
diff --git a/src/expand.c b/src/expand.c
index af9cac9..e57efa6 100644
--- a/src/expand.c
+++ b/src/expand.c
@@ -285,7 +285,7 @@ start:
q = stnputs(p, length, expdest);
being increased is the address which points to the start of the string
> in order to skip the initial character when some conditions are met.
>
> Signed-off-by: Antonio Ospite
> ---
> src/eval.c | 3 ++-
> src/jobs.c | 3 ++-
> 2 files changed, 4 insertions(+), 2 deletions(-)
All applied. Thanks.
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
port!
How about this patch?
---8<---
We set commandname in procargs when we don't have to. This results
in a duplicated output of arg0 when an error occurs.
Reported-by: Olivier Duclos
Signed-off-by: Herbert Xu
diff --git a/src/options.c b/src/options.c
index 6f381e6..a46c23b 100644
---
On Thu, Jan 17, 2019 at 11:07:23PM +0100, Martijn Dekker wrote:
> Op 16-01-19 om 14:32 schreef Herbert Xu:
> > So I'm going to go for a more complicated fix:
>
> The v3 patch introduces a bug:
>
> begin test script
> init() {
> exec 8 } >&
at fd 8 was closed to start with (because the first dup
returned -1 on it).
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
t;[REDIR] Fix redirect restore on saved file...")
Signed-off-by: Herbert Xu
diff --git a/src/redir.c b/src/redir.c
index e67cc0a..4f84a80 100644
--- a/src/redir.c
+++ b/src/redir.c
@@ -128,12 +128,12 @@ redirect(union node *redir, int flags)
p = &sv->renamed[
tstatus if
> necessary.
returncmd itself doesn't jump up but it may be part of a subshell
which would execute a jump to the top as part of the EV_EXIT
optimisation. That's where you'd need to restore the exit status.
Cheers,
--
Email: Herbert Xu
Home Page: http://gon
On Fri, Dec 14, 2018 at 08:02:04AM +, Harald van Dijk wrote:
> On 14/12/2018 03:10, Herbert Xu wrote:
>
> > The reason this is needed is to support a naked return. With
> > your patch a naked return would either have to always return the
> > saved status or the new s
t;set -e" is active,
> but in case it isn't it would stll be good to behave like other shells.
>
> Any comment is welcome.
>
> Thank you,
> Antonio
>
>
> [1] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=779416
>
>
> src/eval.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
Patch applied. Thanks.
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
ompiler warning about missing parentheses
>
> .gitignore | 2 ++
> configure.ac| 8 +---
> src/Makefile.am | 16
> src/eval.c | 2 +-
> src/system.h| 4
> 5 files changed, 16 insertions(+), 16 deletions(-)
Patches 1, 2 and 5 applied.
Herbert Xu wrote:
>
> Here is a new patch that fixes the reported issue for both signal
> traps and the EXIT trap.
This introduced a warning in trap.c. Here is an update to silence
the warning.
---8<---
We unconditionally restore the saved status in exitreset, which
is incorrec
while true; do { true; } https://bugs.busybox.net/show_bug.cgi?id=7748
Signed-off-by: Ron Yorston
I have simplified evaltree so that it simply sets the stack mark
unconditionally. This allows us to remove the stack marks in the
functions called by evaltree.
Signed-off-by: Herbert Xu
diff --gi
mit this patch under its own Subject.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
lacement
isn't up to stratch either. For real security, you'd need a strong
algorithm and periodic rehashing.
If it's hash collisions with a real-world script, please provide an
example.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
a new Subject line? patchwork
is no longer picking up patches posted as a reply.
Please also add a Signed-off-by tag.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
receding the trap action" is `false`, but inside the INT handler, it's
> either `true` or `kill -s INT $$` (I think the latter, but it doesn't
> matter). dash treats it as if it were still `false`.
I think this makes sense. The EXIT trap trumps whatever happens
inside it. FW
ther of which is what we
want.
Please refer to
commit 70c16dd30d4cf824aa895e9f6c095fec741c65a8
Author: Herbert Xu
Date: Mon Oct 6 21:51:26 2014 +0800
[BUILTIN] Return without arguments in a trap should use status outside traps
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
so prints "exit" in ksh, mksh, posh, and bosh.
I'm happy to allow exit traps to be processed here. But we should
be able to achieve the same result without jumping back to main,
by simply jumping back to the start of exitshell instead.
Thanks,
--
Email: Herbert Xu
Home P
not going
to change existing behaviour unless it is clearly wrong.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Sat, Dec 01, 2018 at 04:45:39PM +0800, Herbert Xu wrote:
>
> Hmm, I think this breaks the following case which used to work:
>
> dash -c 'trap "(:; exit) && echo BUG" EXIT; false'
>
> I know this makes no sense but almost every other shell
(void)
> }
> }
> trapcnt = 0;
> + savestatus = -1;
> INTON;
> }
Hmm, I think this breaks the following case which used to work:
dash -c 'trap "(:; exit) && echo BUG" EXIT; false'
I know this makes no sense but almost every
On Thu, Nov 29, 2018 at 03:27:31PM +0100, Martijn Dekker wrote:
> Op 29-11-18 om 12:33 schreef Herbert Xu:
> > Thanks for the report. This patch should fix the problem:
>
> Doesn't work for me, in fact it seems to make no difference.
>
> Here are a few more test cases.
T'
> 1
Thanks for the report. This patch should fix the problem:
---8<---
We unconditionally restore the saved status in exitreset, which
is incorrect as we only want to do it for exitcmd and returncmd.
This patch fixes the problem by introducing EXEND.
Reported-by: Martijn Dekker
Fixes
Antonio Ospite wrote:
>
> can I mark 3/5 as Superseded in patchwork myself?
> Or would that disrupt your workflow?
>
> The intent would be to have one patch less for you to worry about.
I just marked it.
Thanks!
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~h
ps://patchwork.kernel.org/patch/10688471/
I will push it out soon.
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
glibc this patch adds the
pragmas to disable the warning in gcc around our one and only use
of sigsetmask.
It also disables it completely for non-gcc compilers and older
gcc compilers as they may generate a warning too.
Reported-by: Antonio Ospite
Signed-off-by: Herbert Xu
diff --git a/src/syst
s to fix it in just one spot because
you could easily craft another script to exceed the size limit in
any of the other places where we use alloca.
Cheers,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
flushall();
if (outerr(out1))
- warnx("%s: I/O error", commandname);
+ sh_warnx("%s: I/O error", commandname);
status |= outerr(out1);
exitstatus = status;
cmddone:
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
ccept this patch as alloca makes things a lot
simpler in some cases.
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
orm. Thanks!
---8<---
As sigsetmask is set as deprecated in glibc this patch adds the
pragmas to disable the warning in gcc around our one and only use
of sigsetmask.
Reported-by: Antonio Ospite
Signed-off-by: Herbert Xu
diff --git a/src/system.h b/src/system.h
index a8d09b3..f3aa930 100644
---
uot;[SHELL] Optimize dash -c "command" to avoid a fork")
Signed-off-by: Herbert Xu
diff --git a/src/parser.c b/src/parser.c
index c4e6378..1f9e8ec 100644
--- a/src/parser.c
+++ b/src/parser.c
@@ -166,7 +166,7 @@ list(int nlflag)
n1 = NULL;
f
one that
belongs to a parameter expansion at the outer level.
This patch fixes it.
Reported-by: Martijn Dekker
Fixes: 3cd538634f71 ("expand: Do not reprocess data when...")
Signed-off-by: Herbert Xu
diff --git a/src/expand.c b/src/expand.c
index 856b7a9..af9cac9 100644
--- a/src/expand.c
ept a constant string without any
> ugly casting.
>
> Signed-off-by: Devin Hussey
Sorry, I'm not adding this builtin to dash as this conflicts with
the goal of dash trying to be minimal. Perhaps bash or mksh would
be a better option?
Thanks,
--
Email: Herbert Xu
Home Page: http://gondor.apana.org.au/~herbert/
PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt
On Fri, Aug 17, 2018 at 09:08:35PM +0800, Herbert Xu wrote:
> Ron Yorston wrote:
> > I've been continuing to worry about this.
> >
> > In the old code (prior to commit 7c245aa) the TNL token that was
> > detected in list() had actually been read. The
e the same expansions as done on a normal
redirection.
Reported-by: Andrej Shadura
Signed-off-by: Herbert Xu
diff --git a/src/eval.c b/src/eval.c
index 6185db4..328fde3 100644
--- a/src/eval.c
+++ b/src/eval.c
@@ -529,7 +529,7 @@ expredir(union node *n)
case NFROMFD:
1 - 100 of 581 matches
Mail list logo