Displaying 3 results from an estimated 3 matches for "b9ff1402".
2020 Mar 28
0
[klibc:master] dash: shell: Fix clang warnings about "string plus integer"
...intlist(struct output *out, struct strlist *sp, int sep)
while (sp) {
const char *p;
- p = " %s" + (1 - sep);
+ p = " %s";
+ p += (1 - sep);
sep |= 1;
outfmt(out, p, sp->text);
sp = sp->next;
diff --git a/usr/dash/jobs.c b/usr/dash/jobs.c
index 009bbfee..b9ff1402 100644
--- a/usr/dash/jobs.c
+++ b/usr/dash/jobs.c
@@ -1394,7 +1394,8 @@ cmdputs(const char *s)
str = "${";
goto dostr;
case CTLENDVAR:
- str = "\"}" + !(quoted & 1);
+ str = "\"}";
+ str += !(quoted & 1);
quoted >>= 1;...
2020 Mar 28
0
[klibc:update-dash] dash: [JOBS] Fix off-by-one error for multiple of four job numbers
...more more jobs end up allocated
internally.
Signed-off-by: Herbert Xu <herbert at gondor.apana.org.au>
Signed-off-by: Ben Hutchings <ben at decadent.org.uk>
---
usr/dash/jobs.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/usr/dash/jobs.c b/usr/dash/jobs.c
index b9ff1402..c9b631ac 100644
--- a/usr/dash/jobs.c
+++ b/usr/dash/jobs.c
@@ -698,7 +698,7 @@ check:
if (is_number(p)) {
num = atoi(p);
- if (num < njobs) {
+ if (num <= njobs) {
jp = jobtab + num - 1;
if (jp->used)
goto gotit;
2020 Nov 09
4
[[PATCH v1 0/3] Fix clang build warnings
New clangs emit some warnings. The code isn't wrong, but should be updated to
prevent warning creep.
Bill Wendling (3):
[klibc] dash: shell: Fix clang warnings
[klibc] dash: shell: Fix clang warnings about format string
[klibc] Kbuild: use an enum to silence a clang warning
usr/dash/eval.c | 6 +++---
usr/dash/jobs.c | 2 +-
usr/kinit/nfsmount/dummypmap.c