Re: ecpg - GRANT bug

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: ecpg - GRANT bug
Дата
Msg-id 200110291744.f9THi9r25011@candle.pha.pa.us
обсуждение исходный текст
Ответ на Re: ecpg - GRANT bug  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: ecpg - GRANT bug
Список pgsql-bugs
I saw that change from 8 to 7.  I think in the ecpg code that the first
parameter to cat_str is the number of arguments _after_ the first
parameter.

 preproc.c:{ yyval.str = cat_str(3, yyvsp[-2].str, make_str(","), yyvsp[0].str);

so I think the change from 8 -> 7 is correct.


---------------------------------------------------------------------------

> Lee Kindness <lkindness@csl.co.uk> writes:
> > ***************
> > *** 1693,1699 ****
>
> >   GrantStmt:  GRANT privileges ON opt_table relation_name_list TO grantee_list opt_with_grant
> >                   {
> > !                     $$ = cat_str(8, make_str("grant"), $2, make_str("on"), $4, $5, make_str("to"), $7);
> >                   }
> >           ;
>
> > --- 1693,1699 ----
>
> >   GrantStmt:  GRANT privileges ON opt_table relation_name_list TO grantee_list opt_with_grant
> >                   {
> > !                     $$ = cat_str(7, make_str("grant"), $2, make_str("on"), $4, $5, make_str("to"), $7);
> >                   }
> >           ;
>
>
> Uh, isn't the correct fix
>
> !                     $$ = cat_str(8, make_str("grant"), $2, make_str("on"), $4, $5, make_str("to"), $7, $8);
>
> ISTM your patch loses the opt_with_grant clause.  (Of course the backend
> doesn't currently accept that clause anyway, but that's no reason for
> ecpg to drop it.)
>
>             regards, tom lane
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 853-3000
  +  If your life is a hard drive,     |  830 Blythe Avenue
  +  Christ can be your backup.        |  Drexel Hill, Pennsylvania 19026

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

Предыдущее
От: Stephan Szabo
Дата:
Сообщение: Re: Select with backslash '\' character
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Porting issue with openssl and no /dev/random