changeset 1:05651a1b8ba8

f-demime compiles
author Mychaela Falconia <falcon@freecalypso.org>
date Sat, 06 May 2023 06:20:46 +0000
parents 7e0d08176f32
children 1857d0d5a7bd
files .hgignore f-demime/Makefile f-demime/ptext_in.c f-demime/qpdec.c
diffstat 4 files changed, 24 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/.hgignore	Sat May 06 06:20:46 2023 +0000
@@ -0,0 +1,5 @@
+syntax: regexp
+
+\.[oa]$
+
+^f-demime/f-demime$
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/f-demime/Makefile	Sat May 06 06:20:46 2023 +0000
@@ -0,0 +1,16 @@
+CC=	gcc
+CFLAGS=	-O2
+PROG=	f-demime
+OBJS=	attach_out.o b2q_in.o b2q_out.o base64.o finish.o header.o header_end.o\
+	initconv.o main.o msgstate.o ptext_in.o ptext_out.o qpdec.o
+HDRS=	defs.h
+
+all:	${PROG}
+
+${PROG}: ${OBJS}
+	${CC} ${CFLAGS} -o $@ ${OBJS}
+
+${OBJS}: ${HDRS}
+
+clean:
+	rm -f *.o ${PROG}
--- a/f-demime/ptext_in.c	Sat May 06 06:14:03 2023 +0000
+++ b/f-demime/ptext_in.c	Sat May 06 06:20:46 2023 +0000
@@ -31,7 +31,7 @@
 	unsigned newlen;
 
 	newlen = strlen(str);
-	if (out_line_len + newlen >= OUTPUT_LINE_MAX)
+	if (out_line_len + newlen >= OUTPUT_LINE_MAX) {
 		putc('\\', tempfile);
 		putc('\n', tempfile);
 		out_line_len = 0;
@@ -98,7 +98,7 @@
 	case 0x07:
 		simple_escape('a');
 		return;
-	case 0x08':
+	case 0x08:
 		simple_escape('b');
 		return;
 	case 0x09:
--- a/f-demime/qpdec.c	Sat May 06 06:14:03 2023 +0000
+++ b/f-demime/qpdec.c	Sat May 06 06:20:46 2023 +0000
@@ -20,7 +20,7 @@
 	char *cp;
 
 	cp = index(line, '\0');
-	while (cp > line && isspace(cp[-1])
+	while (cp > line && isspace(cp[-1]))
 		cp--;
 	*cp = '\0';
 }