Re: CVE-2017-7484-induced bugs, or, btree cmp functions are not leakproof?

Поиск
Список
Период
Сортировка
От Dilip Kumar
Тема Re: CVE-2017-7484-induced bugs, or, btree cmp functions are not leakproof?
Дата
Msg-id CAFiTN-sc1SEN+6a9o6+XUQWUTMV073CPNgrkdjZz06cxqM5ooQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: CVE-2017-7484-induced bugs, or, btree cmp functions are not leakproof?  (Dilip Kumar <dilipbalaut@gmail.com>)
Ответы Re: CVE-2017-7484-induced bugs, or, btree cmp functions are not leakproof?  (Amit Langote <amitlangote09@gmail.com>)
Список pgsql-hackers
On Thu, Sep 5, 2019 at 2:48 PM Dilip Kumar <dilipbalaut@gmail.com> wrote:
>
> On Thu, Sep 5, 2019 at 2:12 PM Amit Langote <amitlangote09@gmail.com> wrote:
>
> Thanks for the patch, I was almost about to press the send button with
> my patch.  But, this looks similar to my version.
> >
> > On Wed, Sep 4, 2019 at 8:53 AM Tom Lane <tgl@sss.pgh.pa.us> wrote:

>
> Instead of falling back to the child, isn't it make more sense to
> check the permissions on the parent upto which we could translate (it
> may not be the root parent)?
>

  /*
+ * For inheritance child relations, we also need to remember
+ * the root parent.
+ */
+ if (parent->rtekind == RTE_RELATION)
+ rel->inh_root_relid = parent->inh_root_relid > 0 ?
+ parent->inh_root_relid :
+ parent->relid;
+ else
+ /* Child relation of flattened UNION ALL subquery. */
+ rel->inh_root_relid = relid;

With the current changes, parent->inh_root_relid will always be > 0 so
(parent->inh_root_relid > 0) condition doesn't make sence. Right?

-- 
Regards,
Dilip Kumar
EnterpriseDB: http://www.enterprisedb.com



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Pavel Stehule
Дата:
Сообщение: Re: enhance SPI to support EXECUTE commands
Следующее
От: Esteban Zimanyi
Дата:
Сообщение: Specifying attribute slot for storing/reading statistics