* More work on threading.

git-svn-id: svn://rakshasa.no/libtorrent/trunk/rtorrent@1112 e378c898-3ddf-0310-93e7-cc216c733640
This commit is contained in:
rakshasa
2009-12-12 21:30:52 +00:00
parent ef6e4deca9
commit b635f8c852
15 changed files with 278 additions and 48 deletions
+11
View File
@@ -59,6 +59,8 @@
#include "control.h"
#include "command_helpers.h"
#include "thread_worker.h"
torrent::Object
apply_on_state_change(const char* name, const torrent::Object& rawArgs) {
const torrent::Object::list_type& args = rawArgs.as_list();
@@ -350,8 +352,17 @@ d_multicall(const torrent::Object& rawArgs) {
return resultRaw;
}
torrent::Object
test_thread_locking(const torrent::Object& rawArgs) {
worker_thread->queue_item(&ThreadWorker::start_log_counter);
return torrent::Object();
}
void
initialize_command_events() {
ADD_COMMAND_NONE("test.thread_locking", rak::ptr_fn(&test_thread_locking));
ADD_VARIABLE_BOOL("check_hash", true);
ADD_VARIABLE_BOOL("session_lock", true);