Skip to content

Commit a808277

Browse files
committed
lock.
1 parent 4f69541 commit a808277

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/xgboost/cache.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ class DMatrixCache {
7979
auto it = container_.find(p_fmat);
8080
CHECK(it != container_.cend());
8181
// Re-new the cache if this has never been read.
82-
if (it->second.ref.expired() || !it->second.ref->HasBeenRead()) {
82+
if (it->second.ref.expired() || !it->second.ref.lock()->HasBeenRead()) {
8383
expired.push_back(it->first);
8484
} else {
8585
remained.push(it->first);

0 commit comments

Comments
 (0)