From 1533ea88a6b7e4206e21e6405a253f8f62a81cd8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20G=C3=B6ttsche?= Date: Tue, 27 Oct 2020 11:02:34 +0100 Subject: [PATCH] Drop duplicate and always true condition This block is only entered if this->owner is true. --- Vector.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Vector.c b/Vector.c index 4ed0d53d..77f56a88 100644 --- a/Vector.c +++ b/Vector.c @@ -264,9 +264,7 @@ void Vector_set(Vector* this, int idx, void* data_) { if (this->owner) { Object* removed = this->array[idx]; assert (removed != NULL); - if (this->owner) { - Object_delete(removed); - } + Object_delete(removed); } } this->array[idx] = data;