From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-lf1-f65.google.com (mail-lf1-f65.google.com [209.85.167.65]) (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 97F1D452566 for ; Thu, 31 Oct 2019 18:23:08 +0300 (MSK) Received: by mail-lf1-f65.google.com with SMTP id v8so4965664lfa.12 for ; Thu, 31 Oct 2019 08:23:08 -0700 (PDT) Date: Thu, 31 Oct 2019 18:23:06 +0300 From: Konstantin Osipov Message-ID: <20191031152306.GD2636@atlas> References: <71d3e28eadd9ca54d5f564ed25d4276d472d5e6d.1572432961.git.imeevma@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <71d3e28eadd9ca54d5f564ed25d4276d472d5e6d.1572432961.git.imeevma@gmail.com> Subject: Re: [Tarantool-patches] [PATCH v1 1/1] netbox: fix memleak in lbox_tuple_format_new() List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: imeevma@tarantool.org Cc: tarantool-patches@freelists.org, tarantool-patches@dev.tarantool.org, v.shpilevoy@tarantool.org * imeevma@tarantool.org [19/10/30 14:03]: > Memleak appeared due to the fact that when creating a dictionary > its reference count is 1 from the beginning. Later, when the > dictionary is used to create tuple_format, its reference counter > increased by 1 and it became equal to 2. After removing > tuple_format, the reference counter for dict decreased by one, so > it became equal to 1. Since ref counter is not equal to 0, dict > not deleted, causing a memory leak. > > Closes #4588 I wonder if you could come up with a test case? Is memory used by dict accounted in any stats? -- Konstantin Osipov, Moscow, Russia