first vesrion of working socket based rsync. It still needs a lot of
[rsync/rsync.git] / util.c
diff --git a/util.c b/util.c
index 59f9418..f74228e 100644 (file)
--- a/util.c
+++ b/util.c
@@ -446,58 +446,3 @@ void kill_all(int sig)
        }
 }
 
-/* this is the rsync debugging function. Call it with FINFO or FERROR */
-void rprintf(int fd, const char *format, ...)
-{
-       va_list ap;  
-       char buf[1024];
-       int len;
-       FILE *f=NULL;
-
-       va_start(ap, format);
-
-#if HAVE_VSNPRINTF
-       len = vsnprintf(buf, sizeof(buf)-1, format, ap);
-#else
-       len = vsprintf(buf, format, ap);
-#endif
-       va_end(ap);
-
-       if (len < 0) exit_cleanup(1);
-
-       if (fd == FERROR) {
-               f = stderr;
-       } 
-
-       if (fd == FINFO) {
-               extern int am_server;
-               if (am_server) 
-                       f = stderr;
-               else
-                       f = stdout;
-       } 
-
-       if (!f) exit_cleanup(1);
-
-       if (fwrite(buf, len, 1, f) != 1) exit_cleanup(1);
-}
-
-void rflush(int fd)
-{
-       FILE *f = NULL;
-
-       if (fd == FERROR) {
-               f = stderr;
-       } 
-
-       if (fd == FINFO) {
-               extern int am_server;
-               if (am_server) 
-                       f = stderr;
-               else
-                       f = stdout;
-       } 
-
-       if (!f) exit_cleanup(1);
-       fflush(f);
-}