Convert more stuff from #ifdef to dspwrappers.
[gnushogi.git] / gnushogi / rawdsp.c
index d3f3055..e073bae 100644 (file)
@@ -31,6 +31,7 @@
 
 #include <ctype.h>
 #include <signal.h>
+#include <stdarg.h>
 #include <sys/param.h>
 #include <sys/types.h>
 #include <sys/file.h>
@@ -123,6 +124,22 @@ Raw_ShowMessage(char *s)
 
 
 void
+Raw_Printf(const char *format, ...)
+{
+    va_list ap;
+    va_start(ap, format);
+    vprintf(format, ap);
+    va_end(ap);
+}
+
+void
+Raw_RequestInputString(char* buffer)
+{
+    scanf("%s", buffer);
+}
+
+
+void
 Raw_ShowPatternCount(short side, short n)
 {
     if (flag.post)
@@ -315,9 +332,6 @@ Raw_help(void)
            (TCflag) ? CP[93] : CP[92],
            TimeControl.moves[black], TimeControl.clock[black] / 100,
            TCadd/100, MaxSearchDepth);
-
-    signal(SIGINT, Raw_TerminateSearch);
-    signal(SIGQUIT, Raw_TerminateSearch);
 }
 
 
@@ -489,9 +503,6 @@ SetupBoard(void)
 void
 Raw_SearchStartStuff(short side)
 {
-    signal(SIGINT, Raw_TerminateSearch);
-    signal(SIGQUIT, Raw_TerminateSearch);
-
     if (flag.post)
     {
         printf(CP[123],
@@ -969,4 +980,3 @@ Raw_ShowPostnValues(void)
            mtl[opponent], pscore[opponent], GameType[opponent]);
     printf("\nhung black %d hung white %d\n", hung[black], hung[white]);
 }
-