llcache: Do not delete objects if they were iterator targets

Signed-off-by: Daniel Silverstone <dsilvers@digital-scurf.org>
This commit is contained in:
Daniel Silverstone 2019-08-04 10:46:17 +01:00
parent b48e462f0f
commit 6b4610edc9

View File

@ -397,7 +397,7 @@ static nserror llcache_send_event_to_users(llcache_object *object,
user->iterator_target = was_target;
if (user->queued_for_delete) {
if (user->queued_for_delete && !was_target) {
llcache_object_remove_user(object, user);
llcache_object_user_destroy(user);
}