mirror of
https://github.com/jenkinsci/jenkins.git
synced 2026-11-21 15:55:40 +00:00
JENKINS-8702 unit tests improvements
hudson.UDPBroadcastThread#testMulticast hangs when the network isn't enabled on my Linux box: joinGroup throws IOException and the ready lock isn't released. This ready lock is only used in the tests.
This commit is contained in:
1 parent
826d9ddb3d
commit
2e47359a6e
2 files changed
+6
-1
No files matched your search
@@ -61,10 +61,13 @@ public class UDPBroadcastThread extends Thread {
|
||||
@Override
|
||||
public void run() {
|
||||
try {
|
||||
try{
|
||||
mcs.joinGroup(MULTICAST);
|
||||
} finally{
|
||||
ready.signal();
|
||||
}
|
||||
|
||||
while(true) {
|
||||
while(true) {
|
||||
byte[] buf = new byte[2048];
|
||||
DatagramPacket p = new DatagramPacket(buf,buf.length);
|
||||
mcs.receive(p);
|
||||
|
||||
Reference in new issue
Block a user