Dolda2000 GitWeb
/
doldaconnect.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Java: Hopefully working HubListeners.
[doldaconnect.git]
/
lib
/
java
/
dolda
/
dolcon
/
protocol
/
Connection.java
diff --git
a/lib/java/dolda/dolcon/protocol/Connection.java
b/lib/java/dolda/dolcon/protocol/Connection.java
index
03152bc
..
b596639
100644
(file)
--- a/
lib/java/dolda/dolcon/protocol/Connection.java
+++ b/
lib/java/dolda/dolcon/protocol/Connection.java
@@
-183,9
+183,10
@@
public class Connection {
}
}
}
}
- public void qcmd(Command
cmd
) {
+ public void qcmd(Command
... cmds
) {
synchronized(queue) {
synchronized(queue) {
- queue.offer(cmd);
+ for(Command cmd : cmds)
+ queue.offer(cmd);
queue.notifyAll();
}
}
queue.notifyAll();
}
}
@@
-212,6
+213,7
@@
public class Connection {
notifyAll();
}
};
notifyAll();
}
};
+ qcmd(cmd);
synchronized(l) {
while(!donep[0]) {
l.wait();
synchronized(l) {
while(!donep[0]) {
l.wait();
@@
-284,7
+286,9
@@
public class Connection {
out.append(' ');
out.append(quote(s));
}
out.append(' ');
out.append(quote(s));
}
+ out.append("\r\n");
w.write(out.toString());
w.write(out.toString());
+ w.flush();
}
} catch(IOException e) {
throw(new StopCondition(e, false));
}
} catch(IOException e) {
throw(new StopCondition(e, false));
@@
-378,7
+382,6
@@
public class Connection {
code = Integer.parseInt(ct.toString());
ct.setLength(0);
state = "start";
code = Integer.parseInt(ct.toString());
ct.setLength(0);
state = "start";
- continue eat;
} else {
ct.append(c);
}
} else {
ct.append(c);
}