aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/mk
diff options
context:
space:
mode:
authorDan Cross <cross@gajendra.net>2020-01-10 14:44:21 +0000
committerDan Cross <cross@gajendra.net>2020-01-10 14:54:30 +0000
commitfa325e9b42b0bdfb48857d1958d9fb7ceac55151 (patch)
tree81d26256d152435135bcb1ae43121979a49f5f2b /src/cmd/mk
parent77a0a5b5194d4441c86de097f2aae297cb75e2c2 (diff)
downloadplan9port-fa325e9b42b0bdfb48857d1958d9fb7ceac55151.tar.gz
plan9port-fa325e9b42b0bdfb48857d1958d9fb7ceac55151.tar.bz2
plan9port-fa325e9b42b0bdfb48857d1958d9fb7ceac55151.zip
Trivial changes: whitespace and modes.
Remote whitespace at the ends of lines. Remove blank lines from the ends of files. Change modes on source files so that they are not executable. Signed-off-by: Dan Cross <cross@gajendra.net>
Diffstat (limited to 'src/cmd/mk')
-rw-r--r--src/cmd/mk/env.c2
-rw-r--r--src/cmd/mk/rule.c2
-rw-r--r--src/cmd/mk/run.c2
-rw-r--r--src/cmd/mk/sh.c1
-rw-r--r--src/cmd/mk/sys.h1
-rw-r--r--src/cmd/mk/unix.c6
-rw-r--r--src/cmd/mk/varsub.c8
-rw-r--r--src/cmd/mk/word.c2
8 files changed, 11 insertions, 13 deletions
diff --git a/src/cmd/mk/env.c b/src/cmd/mk/env.c
index 11df34e3..d7c6481d 100644
--- a/src/cmd/mk/env.c
+++ b/src/cmd/mk/env.c
@@ -142,7 +142,7 @@ buildenv(Job *j, int slot)
for(i = 0; *p; i++, p++){
if((j->r->attr&REGEXP) && j->match[i])
envupd(*p, newword(j->match[i]));
- else
+ else
envupd(*p, newword(""));
}
return envy;
diff --git a/src/cmd/mk/rule.c b/src/cmd/mk/rule.c
index 30728197..537d2d75 100644
--- a/src/cmd/mk/rule.c
+++ b/src/cmd/mk/rule.c
@@ -76,7 +76,7 @@ dumpr(char *s, Rule *r)
{
if(r == nil)
return;
- Bprint(&bout, "%s: start=%ld shelltype=%s shellcmd=%s\n",
+ Bprint(&bout, "%s: start=%ld shelltype=%s shellcmd=%s\n",
s, r, r->shellt->name, wtos(r->shellcmd, ' '));
for(; r; r = r->next){
Bprint(&bout, "\tRule %ld: %s[%d] attr=%x next=%ld chain=%ld alltarget='%s'",
diff --git a/src/cmd/mk/run.c b/src/cmd/mk/run.c
index dd225c0d..6f60cede 100644
--- a/src/cmd/mk/run.c
+++ b/src/cmd/mk/run.c
@@ -29,7 +29,7 @@ run(Job *j)
for(jj = jobs; jj->next; jj = jj->next)
;
jj->next = j;
- } else
+ } else
jobs = j;
j->next = 0;
/* this code also in waitup after parse redirect */
diff --git a/src/cmd/mk/sh.c b/src/cmd/mk/sh.c
index e2566514..d8f205c8 100644
--- a/src/cmd/mk/sh.c
+++ b/src/cmd/mk/sh.c
@@ -203,4 +203,3 @@ Shell shshell = {
shcopyq,
shmatchname
};
-
diff --git a/src/cmd/mk/sys.h b/src/cmd/mk/sys.h
index 03a9d058..f520b066 100644
--- a/src/cmd/mk/sys.h
+++ b/src/cmd/mk/sys.h
@@ -2,4 +2,3 @@
#include <libc.h>
#include <bio.h>
#include <regexp.h>
-
diff --git a/src/cmd/mk/unix.c b/src/cmd/mk/unix.c
index c63d3cef..37f05b71 100644
--- a/src/cmd/mk/unix.c
+++ b/src/cmd/mk/unix.c
@@ -23,7 +23,7 @@ readenv(void)
Word *w;
for(p = environ; *p; p++){
-/* rsc 5/5/2004 -- This misparses fn#cd={whatever}
+/* rsc 5/5/2004 -- This misparses fn#cd={whatever}
s = shname(*p);
if(*s == '=') {
*s = 0;
@@ -111,7 +111,7 @@ shargv(Word *cmd, int extra, char ***pargv)
n = 0;
for(w=cmd; w; w=w->next)
n++;
-
+
argv = Malloc((n+extra+1)*sizeof(argv[0]));
i = 0;
for(w=cmd; w; w=w->next)
@@ -119,7 +119,7 @@ shargv(Word *cmd, int extra, char ***pargv)
argv[n] = 0;
*pargv = argv;
return n;
-}
+}
int
execsh(char *args, char *cmd, Bufblock *buf, Envy *e, Shell *sh, Word *shellcmd)
diff --git a/src/cmd/mk/varsub.c b/src/cmd/mk/varsub.c
index f858a92a..b6c0ab0f 100644
--- a/src/cmd/mk/varsub.c
+++ b/src/cmd/mk/varsub.c
@@ -61,7 +61,7 @@ varmatch(char *name)
{
Word *w;
Symtab *sym;
-
+
sym = symlook(name, S_VAR, 0);
if(sym){
/* check for at least one non-NULL value */
@@ -107,7 +107,7 @@ expandvar(char **s)
}
*end = 0;
*s = end+1;
-
+
sym = symlook(buf->start, S_VAR, 0);
if(sym == 0 || sym->u.ptr == 0)
w = newword(buf->start);
@@ -173,7 +173,7 @@ subsub(Word *v, char *s, char *end)
while(w->next)
w = w->next;
}
- if(PERCENT(*cp) && nmid > 0){
+ if(PERCENT(*cp) && nmid > 0){
if(w){
bufcpy(buf, w->s, strlen(w->s));
bufcpy(buf, enda, nmid);
@@ -205,7 +205,7 @@ subsub(Word *v, char *s, char *end)
}
if(w == 0)
h = w = newword(v->s);
-
+
if(head == 0)
head = h;
else
diff --git a/src/cmd/mk/word.c b/src/cmd/mk/word.c
index f94c4fd7..e1e52a1c 100644
--- a/src/cmd/mk/word.c
+++ b/src/cmd/mk/word.c
@@ -29,7 +29,7 @@ stow(char *s)
head = w = new;
while(w->next)
w = w->next;
-
+
}
if (!head)
head = newword("");