From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Date: Wed, 19 Jun 2019 19:11:48 +0300 From: Vladimir Davydov Subject: Re: [tarantool-patches] Re: [PATCH v3 2/6] box: rework box_lua_{call, eval} to use input port Message-ID: <20190619161147.ruju54bvgtp2gd4x@esperanza> References: <20190618121256.hexjwmwh4tdjmas3@esperanza> <9018c744-6018-23f4-bb36-1c144a8c4724@tarantool.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <9018c744-6018-23f4-bb36-1c144a8c4724@tarantool.org> To: Kirill Shcherbatov Cc: tarantool-patches@freelists.org List-ID: On Wed, Jun 19, 2019 at 06:51:15PM +0300, Kirill Shcherbatov wrote: > >> module_gc(module); > >> + if (rc != 0) { > >> + if (diag_last_error(&fiber()->diag) == NULL) { > >> + /* Stored procedure forget to set diag */ > >> + diag_set(ClientError, ER_PROC_C, "unknown error"); > >> + } > >> + port_destroy(out_port); > >> + return -1; > >> + } > > > >Shouldn't you call region_truncate() here to clean up after the function > >and possibly port_get_msgpack()? > No, the func_c_call implementation must clean region by it's own. But you did add region_truncate() to the place I pointed to. I'm confused... Anyway, please resend the whole series in a separate thread rather than bloating this one.