summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2016-10-11 20:25:58 +0000
committerLaurent Bercot <ska-skaware@skarnet.org>2016-10-11 20:25:58 +0000
commit03157b1649b22dd06f0d0e1da464bee2d3a2811c (patch)
tree6640377eddf4b0b28e47befa7445688fa28bb2b3 /src
parent8fcdaa5073add0a8940e1d8a54acf01bb236e03f (diff)
downloadexecline-03157b1649b22dd06f0d0e1da464bee2d3a2811c.tar.xz
bugfix: backtick segfaulted on empty remainder (thanks jjk)
Diffstat (limited to 'src')
-rw-r--r--src/execline/backtick.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/execline/backtick.c b/src/execline/backtick.c
index 2661983..38ab0af 100644
--- a/src/execline/backtick.c
+++ b/src/execline/backtick.c
@@ -71,7 +71,7 @@ int main (int argc, char const **argv, char const *const *envp)
if (!stralloc_cats(&modif, def)) strerr_diefu1sys(111, "stralloc_catb") ;
}
}
- if (argc == argc1 - 1) return 0 ;
+ if (argc1 == argc - 1) return 0 ;
if (!stralloc_0(&modif)) strerr_diefu1sys(111, "stralloc_catb") ;
{
unsigned int reallen = str_len(modif.s) ;