From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Subject: Re: [tarantool-patches] Re: [PATCH v1 1/1] box: support reload whole module References: <8846b566-24c5-9f11-ca29-18baed551921@tarantool.org> <20180711124656.pzuh254bjku3k2xc@esperanza> From: Kirill Shcherbatov Message-ID: Date: Wed, 11 Jul 2018 15:52:46 +0300 MIME-Version: 1.0 In-Reply-To: <20180711124656.pzuh254bjku3k2xc@esperanza> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit To: tarantool-patches@freelists.org, Vladimir Davydov List-ID: On 11.07.2018 15:46, Vladimir Davydov wrote: > AFAIU a user may reload a whole module only if he has the global EXECUTE > privilege (because we don't have such an entity as module in our data > dictionary to grant access rights for). access_check_func(), which is > called by func_reload(), already checks the global EXECUTE privilege and > returns 0 (success) if it is set, no matter if the function was found or > not. So all you have to do is call module_reload() from func_reload() if > access_check_func() returned func = NULL, no? No, this call iterates through all loaded functions of specified module and reload all that belongs to initiator if any.