Re: ECPG: "char*" instead of "const char*" in ecpglib.h

Поиск
Список
Период
Сортировка
От Qingqing Zhou
Тема Re: ECPG: "char*" instead of "const char*" in ecpglib.h
Дата
Msg-id Pine.LNX.4.58.0511121713520.8837@eon.cs
обсуждение исходный текст
Ответ на ECPG: "char*" instead of "const char*" in ecpglib.h  (Tomasz Ostrowski <tometzky@batory.org.pl>)
Список pgsql-bugs
On Wed, 9 Nov 2005, Tomasz Ostrowski wrote:
>
> Using "char*" as an argument type instead of "const char*" in ecpglib.h
> causes that for example the following sample program, basically
> copied from docmentation
> http://www.postgresql.org/docs/8.1/interactive/ecpg-dynamic.html ,
> does not compile using "gcc-4.0.1":
>
> $g++ test.c -lecpg
> test.pgc: In function 'int main()':
> test.pgc:11: error: invalid conversion from 'const char*' to 'char*'
> test.pgc:11: error:   initializing argument 3 of 'bool ECPGprepare(int, char*, char*)'
>

Agreed. A patch has been submitted to pg-patches.

Regards,
Qingqing

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

Предыдущее
От: "Qingqing Zhou"
Дата:
Сообщение: Re: BUG #2038: fetch items truncated
Следующее
От: "Qingqing Zhou"
Дата:
Сообщение: Re: BUG #2030: Chinese character support error