Update Fluidsynth to v2.0.2
[ardour.git] / libs / fluidsynth / src / fluid_sys.c
index c9662f7787d869ee682017b11a8a7a238eeec770..cce778b3c4408fb8445a7f7a76c3fdd49567c56c 100644 (file)
@@ -1280,6 +1280,7 @@ fluid_istream_readline(fluid_istream_t in, fluid_ostream_t out, char *prompt,
 
         FLUID_SNPRINTF(buf, len, "%s", line);
         buf[len - 1] = 0;
+        add_history(buf);
 
         free(line);
         return 1;
@@ -1331,9 +1332,10 @@ fluid_istream_gets(fluid_istream_t in, char *buf, int len)
         }
         else
         {
+#ifdef NETWORK_SUPPORT
             n = recv(in & ~FLUID_SOCKET_FLAG, &c, 1, 0);
-
             if(n == SOCKET_ERROR)
+#endif
             {
                 return -1;
             }
@@ -1406,10 +1408,13 @@ fluid_ostream_printf(fluid_ostream_t out, const char *format, ...)
             return write(out, buf, FLUID_STRLEN(buf));
         }
 
+#ifdef NETWORK_SUPPORT
         /* Socket */
         retval = send(out & ~FLUID_SOCKET_FLAG, buf, FLUID_STRLEN(buf), 0);
-
         return retval != SOCKET_ERROR ? retval : -1;
+#else
+        return -1;
+#endif
     }
 #endif
 }