commit df644ef1377aab6bd01890cac2e73e9e22b7e6d1
parent d939c95346f048faea3bee63ee6139fbfb68e081
Author: Ellenor Bjornsdottir <ellenor@umbrellix.net>
Date: Wed, 31 Dec 2025 10:13:04 +0000
Merge branch 'trunk' of git.umbrellix.net:nightmaremail into trunk
Diffstat:
8 files changed, 16 insertions(+), 11 deletions(-)
diff --git a/.gitignore b/.gitignore
@@ -388,3 +388,4 @@ nmail-smtpd
test.c
test.o
teste
+pending-prototypes
diff --git a/Makefile b/Makefile
@@ -0,0 +1 @@
+Makefile.legacy
+\ No newline at end of file
diff --git a/Makefile.legacy b/Makefile.legacy
@@ -3,9 +3,13 @@
SHELL=/bin/sh
NROFF?=nroff
-default: it
+.PHONY: check clean default it man test pending-prototypes
+
+maint: pending-prototypes
+pending-prototypes:
+ grep '()' include/*.h >$@
-.PHONY: check clean default it man test
+default: it
.SUFFIXES: .0 .1 .5 .7 .8
diff --git a/TARGETS b/TARGETS
@@ -379,3 +379,4 @@ qmail-send.service
src/netstrings.o
src/nmail-smtpd.o
nmail-smtpd
+pending-prototypes
diff --git a/include/fd.h b/include/fd.h
@@ -1,7 +1,7 @@
#ifndef FD_H
#define FD_H
-extern int fd_copy();
-extern int fd_move();
+extern int fd_copy(int to, int from);
+extern int fd_move(int to, int from);
#endif
diff --git a/src/fd_copy.c b/src/fd_copy.c
@@ -2,9 +2,7 @@
#include <unistd.h>
#include "fd.h"
-int fd_copy(to,from)
-int to;
-int from;
+int fd_copy(int to, int from)
{
if (to == from) return 0;
if (fcntl(from,F_GETFL,0) == -1) return -1;
diff --git a/src/fd_move.c b/src/fd_move.c
@@ -1,9 +1,7 @@
#include <unistd.h>
#include "fd.h"
-int fd_move(to,from)
-int to;
-int from;
+int fd_move(int to, int from)
{
if (to == from) return 0;
if (fd_copy(to,from) == -1) return -1;
diff --git a/src/scan_ulong.c b/src/scan_ulong.c
@@ -10,7 +10,8 @@ unsigned int scan_ulong(char *s, unsigned long *u)
*u = result; return pos;
}
-/* no quick LUTtery; specific functions could use a static LUT but that's out scope here */
+/* no quick LUTtery; specific functions could use a static LUT but that's out scope here
+ * this can also only work up to... base 127? 255? mi ne scias */
static inline long first(char x, char *iny, unsigned long ylen)
{
int i;