Re: Add missing const qualifier in ECPG - Mailing list pgsql-patches

From Peter Eisentraut
Subject Re: Add missing const qualifier in ECPG
Date
Msg-id 200511130014.02521.peter_e@gmx.net
Whole thread Raw
In response to Add missing const qualifier in ECPG  (Qingqing Zhou <zhouqq@cs.toronto.edu>)
Responses Re: Add missing const qualifier in ECPG
Re: Add missing const qualifier in ECPG
List pgsql-patches
Qingqing Zhou wrote:
> ***************
> *** 149,155 ****
>       if (!(*stmt = (struct statement *) ECPGalloc(sizeof(struct
> statement), lineno))) return false;
>
> !     (*stmt)->command = query;
>       (*stmt)->connection = connection;
>       (*stmt)->lineno = lineno;
>       (*stmt)->compat = compat;
> --- 150,156 ----
>       if (!(*stmt = (struct statement *) ECPGalloc(sizeof(struct
> statement), lineno))) return false;
>
> !     (*stmt)->command = (char *)query;
>       (*stmt)->connection = connection;
>       (*stmt)->lineno = lineno;
>       (*stmt)->compat = compat;

This sort of "cheating" should be avoided.

--
Peter Eisentraut
http://developer.postgresql.org/~petere/

pgsql-patches by date:

Previous
From: Qingqing Zhou
Date:
Subject: Add missing const qualifier in ECPG
Next
From: Qingqing Zhou
Date:
Subject: Re: Add missing const qualifier in ECPG