summaryrefslogtreecommitdiff
path: root/src/newinclude.c
diff options
context:
space:
mode:
authorJannis Hoffmann <jannis@fehcom.de>2024-07-03 19:03:11 +0200
committerJannis Hoffmann <jannis@fehcom.de>2024-07-03 19:03:11 +0200
commit20b85c03e751b4876fa3c92040464e483172b746 (patch)
tree734fadbfdbc143ec4465093857f4c239448715e0 /src/newinclude.c
parenta6a7d6ce079cabdaf2fa502b2e2cf15e5428ac6f (diff)
manual format adjustment
Diffstat (limited to 'src/newinclude.c')
-rw-r--r--src/newinclude.c13
1 files changed, 6 insertions, 7 deletions
diff --git a/src/newinclude.c b/src/newinclude.c
index 4e1bab2..4991b43 100644
--- a/src/newinclude.c
+++ b/src/newinclude.c
@@ -18,12 +18,11 @@
#define WHO "newinclude"
-int rename(const char *, const char *); // stdio.h
-
void nomem()
{
logmsg(WHO, 111, FATAL, "out of memory");
}
+
void usage()
{
logmsg(WHO, 100, USAGE, "newinclude list");
@@ -45,6 +44,7 @@ void readerr()
{
logmsg(WHO, 111, FATAL, B("unable to read: ", fnlist));
}
+
void writeerr()
{
logmsg(WHO, 111, FATAL, B("unable to write to ", fntmp));
@@ -228,8 +228,8 @@ void parseline()
if (!token822_readyplus(&tokaddr, 1)) nomem();
tokaddr.len = 0;
- while (t > beginning) switch ((--t)->type)
- {
+ while (t > beginning) {
+ switch ((--t)->type) {
case TOKEN822_SEMI: break; /*XXX*/
case TOKEN822_COLON:
if (t >= beginning + 2)
@@ -275,13 +275,12 @@ void parseline()
if (!token822_append(&tokaddr, t)) nomem();
continue;
}
+ }
if (tokaddr.len) gotaddr();
}
-int main(argc, argv)
-int argc;
-char **argv;
+int main(int argc, char **argv)
{
int fd;