Skip to content

Commit 062da84

Browse files
committed
Revert "CPP-987 Make handling of future callbacks play nicely with the predicate guards around cass_future_wait (#559)"
This reverts commit 4a0e4f7.
1 parent e05897d commit 062da84

File tree

1 file changed

+1
-5
lines changed

1 file changed

+1
-5
lines changed

src/future.cpp

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -189,18 +189,14 @@ bool Future::set_callback(Future::Callback callback, void* data) {
189189
}
190190

191191
void Future::internal_set(ScopedMutex& lock) {
192+
is_set_ = true;
192193
if (callback_) {
193194
Callback callback = callback_;
194195
void* data = data_;
195196
lock.unlock();
196197
callback(CassFuture::to(this), data);
197198
lock.lock();
198199
}
199-
200-
// CPP-987 Set this after the callbacks run to avoid unexpected exits
201-
// from wait ops due to spurious wakeups
202-
is_set_ = true;
203-
204200
// Broadcast after we've run the callback so that threads waiting
205201
// on this future see the side effects of the callback.
206202
uv_cond_broadcast(&cond_);

0 commit comments

Comments
 (0)