Java: Fix ecmd and Writer bugs.
authorFredrik Tolf <fredrik@dolda2000.com>
Sun, 27 Jan 2008 21:38:12 +0000 (22:38 +0100)
committerFredrik Tolf <fredrik@dolda2000.com>
Sun, 27 Jan 2008 21:38:12 +0000 (22:38 +0100)
lib/java/dolda/dolcon/protocol/Connection.java

index 03152bc..43cf5a3 100644 (file)
@@ -212,6 +212,7 @@ public class Connection {
                    notifyAll();
                }
            };
+       qcmd(cmd);
        synchronized(l) {
            while(!donep[0]) {
                l.wait();
@@ -284,7 +285,9 @@ public class Connection {
                            out.append(' ');
                        out.append(quote(s));
                    }
+                   out.append("\r\n");
                    w.write(out.toString());
+                   w.flush();
                }
            } catch(IOException e) {
                throw(new StopCondition(e, false));