[prev in list] [next in list] [prev in thread] [next in thread]
List: gnash-commit
Subject: [Gnash-commit] /srv/bzr/gnash/rtmp r9794: don't block in wait()
From: rob () welcomehome ! org
Date: 2008-11-27 16:14:42
Message-ID: E1L5lHi-0006PZ-GS () sv ! gnu ! org
[Download RAW message or body]
------------------------------------------------------------
revno: 9794
committer: rob@welcomehome.org
branch nick: rtmp
timestamp: Thu 2008-11-27 09:14:42 -0700
message:
don't block in wait() when in signle threaded mode.
modified:
cygnal/cygnal.cpp
["r9794.diff" (r9794.diff)]
=== modified file 'cygnal/cygnal.cpp'
--- a/cygnal/cygnal.cpp 2008-11-22 18:27:33 +0000
+++ b/cygnal/cygnal.cpp 2008-11-27 16:14:42 +0000
@@ -524,6 +524,11 @@
// connect at a time. This is to make it easier to debug
// things when you have a heavily threadd application.
args->netfd = net.newConnection(true, fd);
+ if (args->netfd <= 0) {
+ log_debug("No new network connections");
+ continue;
+ }
+
log_debug("New network connection for fd #%d", args->netfd);
struct pollfd fds;
@@ -611,9 +616,12 @@
}
} else {
log_debug("nothing to wait for...");
- hand->wait();
- log_debug("Got new network file descriptor to watch");
-// return;
+ if (crcfile.getThreadingFlag()) {
+ hand->wait();
+ log_debug("Got new network file descriptor to watch");
+ } else {
+ return;
+ }
}
}
} // end of dispatch_handler
_______________________________________________
Gnash-commit mailing list
Gnash-commit@gnu.org
http://lists.gnu.org/mailman/listinfo/gnash-commit
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic