search for: sprint_status

Displaying 6 results from an estimated 6 matches for "sprint_status".

2020 Mar 28
0
[klibc:update-dash] dash: jobs: Replace some uses of fmtstr with stpcpy/stpncpy
...gs <ben at decadent.org.uk> --- usr/dash/jobs.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/usr/dash/jobs.c b/usr/dash/jobs.c index 2c277153..9e7244e1 100644 --- a/usr/dash/jobs.c +++ b/usr/dash/jobs.c @@ -404,12 +404,11 @@ out: #endif STATIC int -sprint_status(char *s, int status, int sigonly) +sprint_status(char *os, int status, int sigonly) { - int col; + char *s = os; int st; - col = 0; st = WEXITSTATUS(status); if (!WIFEXITED(status)) { #if JOBS @@ -425,21 +424,21 @@ sprint_status(char *s, int status, int sigonly) goto out; #endif...
2010 Oct 19
3
[PATCH] Fix up 3 klibc build warnings.
...fixdep.c: In function 'traps': klibc/scripts/basic/fixdep.c:368: warning: dereferencing type-punned pointer will break strict-aliasing rules klibc/scripts/basic/fixdep.c:370: warning: dereferencing type-punned pointer will break strict-aliasing rules klibc/usr/dash/jobs.c: In function 'sprint_status': klibc/usr/dash/jobs.c:427: warning: format not a string literal and no format arguments klibc/usr/dash/trap.c: In function 'exitshell': klibc/usr/dash/trap.c:354: warning: variable 'status' might be clobbered by 'longjmp' or 'vfork' Signed-off-by: Maciej ?enc...
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
2020 Mar 27
2
[PATCH v2 5/5] Clean up clang warnings
...ar *p; - p = " %s" + (1 - sep); + p = &" %s"[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 009bbfeee47e..776983b708d6 100644 --- a/usr/dash/jobs.c +++ b/usr/dash/jobs.c @@ -426,7 +426,7 @@ sprint_status(char *s, int status, int sigonly) goto out; #endif } - col = fmtstr(s, 32, strsignal(st)); + col = fmtstr(s, 32, "%s", strsignal(st)); #ifdef WCOREDUMP if (WCOREDUMP(status)) { col += fmtstr(s + col, 16, " (core dumped)"); @@ -1394,7 +1394,7 @@ cmdputs(const c...
2020 Mar 28
0
[klibc:update-dash] dash: eval: Add vfork support
...de "redir.h" #include "show.h" @@ -97,6 +98,9 @@ static int ttyfd = -1; /* current job */ static struct job *curjob; +/* Set if we are in the vforked child */ +int vforked; + STATIC void set_curjob(struct job *, unsigned); STATIC int jobno(const struct job *); STATIC int sprint_status(char *, int, int); @@ -839,20 +843,29 @@ growjobtab(void) * Called with interrupts off. */ -STATIC inline void -forkchild(struct job *jp, union node *n, int mode) +static void forkchild(struct job *jp, union node *n, int mode) { + int lvforked; int oldlvl; TRACE(("Child shell %d\n...
2020 Mar 27
12
[PATCH 0/5] Clang compatibility patches
This is a series of patches for clang compatibility: - Using flags needed flags and removing unsupported flags. - Adding support for clang's LLD linker. - Removing a variety of warnings. Bill Wendling (3): [klibc] Kbuild: use "libc.a" with clang [klibc] Kbuild: Add "-fcommon" for clang builds [klibc] Clean up clang warnings Michael Davidson (1): [klibc] Kbuild: