From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf1-f68.google.com (mail-lf1-f68.google.com [209.85.167.68]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id AA6BC4696C3 for ; Thu, 9 Apr 2020 11:19:24 +0300 (MSK) Received: by mail-lf1-f68.google.com with SMTP id z23so7242824lfh.8 for ; Thu, 09 Apr 2020 01:19:24 -0700 (PDT) Date: Thu, 9 Apr 2020 11:19:23 +0300 From: Konstantin Osipov Message-ID: <20200409081923.GB21437@atlas> References: <73e1f0baf18ec008312d91db4449447b3c06aa86.1586381297.git.korablev@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <73e1f0baf18ec008312d91db4449447b3c06aa86.1586381297.git.korablev@tarantool.org> Subject: Re: [Tarantool-patches] [PATCH 2/2] vinyl: clean-up read views if *_build_history() fails List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Nikita Pettik Cc: tarantool-patches@dev.tarantool.org, v.shpilevoy@tarantool.org * Nikita Pettik [20/04/09 00:39]: > if (vy_write_iterator_build_history(stream, &raw_count, > - &is_first_insert) != 0) > + &is_first_insert) != 0) { > + for (int i = 0; i < stream->rv_count; ++i) > + stream->read_views[i].history = NULL; This violates stream encapsulation and should be a method of the stream. Otherwise lgtm. -- Konstantin Osipov, Moscow, Russia