Attempt to fix line endings in stdio doors
This commit is contained in:
parent
90986ffbe9
commit
d315c1eaa7
2
Makefile
2
Makefile
@ -9,7 +9,7 @@ OBJ = inih/ini.o bbs.o main.o users.o main_menu.o mail_menu.o doors.o bbs_list.o
|
||||
$(CC) -c -o $@ $< $(CFLAGS)
|
||||
|
||||
magicka: $(OBJ)
|
||||
$(CC) -o magicka -o $@ $^ $(CFLAGS) -L/usr/local/lib -lsqlite3 $(JAMLIB) $(ZMODEM) -lutil
|
||||
$(CC) -o magicka -o $@ $^ $(CFLAGS) -L/usr/local/lib -lsqlite3 $(JAMLIB) $(ZMODEM) -lutil
|
||||
|
||||
.PHONY: clean
|
||||
|
||||
|
5
doors.c
5
doors.c
@ -200,6 +200,11 @@ void rundoor(int socket, struct user_record *user, char *cmd, int stdio) {
|
||||
disconnect(socket);
|
||||
return;
|
||||
}
|
||||
if (c == '\r') {
|
||||
c == '\n';
|
||||
} else if (c == '\n' || c == '\0') {
|
||||
continue;
|
||||
}
|
||||
write(master, &c, 1);
|
||||
} else if (FD_ISSET(master, &fdset)) {
|
||||
len = read(master, &c, 1);
|
||||
|
@ -1,4 +1,4 @@
|
||||
CC = gcc $(CPPFLAGS) $(CFLAGS) -D__LINUX__ $(LDFLAGS) -Wall
|
||||
CC = cc $(CPPFLAGS) $(CFLAGS) -D__LINUX__ $(LDFLAGS) -Wall
|
||||
AR = ar -ru
|
||||
RM = rm -f
|
||||
|
||||
|
Reference in New Issue
Block a user