Commit 71526f6a authored by Mart Lubbers's avatar Mart Lubbers

debug again

parent 78b3c8b6
...@@ -2,7 +2,7 @@ test: test.icl TTY.icl TTY.dcl Clean\ System\ Files/ctty.o ...@@ -2,7 +2,7 @@ test: test.icl TTY.icl TTY.dcl Clean\ System\ Files/ctty.o
clm -dynamics -l -no-pie -I /opt/clean/lib/Dynamics $(basename $<) -o $@ clm -dynamics -l -no-pie -I /opt/clean/lib/Dynamics $(basename $<) -o $@
Clean\ System\ Files/ctty.o: tty.c Clean\ System\ Files/ctty.o: tty.c
gcc-5 -c $< -o "$@" gcc-5 -DDEBUG -c $< -o "$@"
clean: clean:
$(RM) -r Clean\ System\ Files/* test $(RM) -r Clean\ System\ Files/* test
...@@ -12,9 +12,9 @@ ...@@ -12,9 +12,9 @@
#include "Clean.h" #include "Clean.h"
#ifdef DEBUG #ifdef DEBUG
#define debug(s, ...) {printf(s "\n", #__VA_ARGS__); fflush(stdout);} #define debug(s) {puts(s); fflush(stdout);}
#else #else
#define debug(s, ...) ; #define debug(s) ;
#endif #endif
#ifdef __APPLE__ #ifdef __APPLE__
...@@ -198,7 +198,7 @@ void ttyreadline(int fd, CleanString *result, int *fdo) ...@@ -198,7 +198,7 @@ void ttyreadline(int fd, CleanString *result, int *fdo)
CleanStringLength(readlinecl) = charsread; CleanStringLength(readlinecl) = charsread;
*fdo = fd; *fdo = fd;
debug("Recv: '%s'", buf); free(buf);
debug("ttyreadline-done"); debug("ttyreadline-done");
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment