From a4a4cc2f1c546915fbb9efe8e21a1189d235b18c Mon Sep 17 00:00:00 2001 From: Laurent Bercot Date: Sun, 16 Oct 2016 19:10:46 +0000 Subject: bugfix: runblock -r segfaulted on too few arguments (thanks jjk) --- src/execline/runblock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/execline/runblock.c b/src/execline/runblock.c index a654023..4e3808d 100644 --- a/src/execline/runblock.c +++ b/src/execline/runblock.c @@ -77,7 +77,7 @@ int main (int argc, char const *const *argv, char const *const *envp) if (flagr) /* put remainder envvars into v */ { - if (++m == sharp) return 0 ; + if (++m > sharp) return 0 ; if (!genalloc_ready(char const *, &v, sharp - m + 2)) strerr_diefu1sys(111, "genalloc_ready") ; for (; m <= sharp ; m++) -- cgit v1.2.3