throttle: allow take(0)

This commit is contained in:
Sage Weil 2010-06-08 15:36:55 -07:00
parent 0dc9569557
commit 26a4d0eacf

View File

@ -62,7 +62,7 @@ public:
}
int64_t take(int64_t c = 1) {
assert(c > 0);
assert(c >= 0);
Mutex::Locker l(lock);
count += c;
return count;