added priority to disk io jobs

This commit is contained in:
Arvid Norberg
2007-09-16 01:34:06 +00:00
parent 5b8ce7f6a0
commit 9364a2d01d
4 changed files with 19 additions and 2 deletions

View File

@@ -50,6 +50,7 @@ namespace libtorrent
, buffer_size(0)
, piece(0)
, offset(0)
, priority(0)
{}
enum action_t
@@ -72,6 +73,12 @@ namespace libtorrent
// to the error message
std::string str;
// priority decides whether or not this
// job will skip entries in the queue or
// not. It always skips in front of entries
// with lower priority
int priority;
// this is called when operation completes
boost::function<void(int, disk_io_job const&)> callback;
};