@@ -172,52 +172,68 @@ bool ecpg_get_data(const PGresult *, int, int, int, enum ECPGttype type,
172172#ifdef ENABLE_THREAD_SAFETY
173173void ecpg_pthreads_init (void );
174174#endif
175- struct connection * ecpg_get_connection (const char * );
176- char * ecpg_alloc (long , int );
177- char * ecpg_auto_alloc (long , int );
178- char * ecpg_realloc (void * , long , int );
179- void ecpg_free (void * );
180- bool ecpg_init (const struct connection * , const char * , const int );
181- char * ecpg_strdup (const char * , int );
182- const char * ecpg_type_name (enum ECPGttype );
183- int ecpg_dynamic_type (Oid );
184- int sqlda_dynamic_type (Oid , enum COMPAT_MODE );
175+ struct connection * ecpg_get_connection (const char * connection_name );
176+ char * ecpg_alloc (long size , int lineno );
177+ char * ecpg_auto_alloc (long size , int lineno );
178+ char * ecpg_realloc (void * ptr , long size , int lineno );
179+ void ecpg_free (void * ptr );
180+ bool ecpg_init (const struct connection * con ,
181+ const char * connection_name ,
182+ const int lineno );
183+ char * ecpg_strdup (const char * string , int lineno );
184+ const char * ecpg_type_name (enum ECPGttype typ );
185+ int ecpg_dynamic_type (Oid type );
186+ int sqlda_dynamic_type (Oid type , enum COMPAT_MODE compat );
185187void ecpg_clear_auto_mem (void );
186188
187189struct descriptor * ecpg_find_desc (int line , const char * name );
188190
189- struct prepared_statement * ecpg_find_prepared_statement (const char * ,
190- struct connection * , struct prepared_statement * * );
191+ struct prepared_statement * ecpg_find_prepared_statement (const char * name ,
192+ struct connection * con ,
193+ struct prepared_statement * * prev_ );
191194
192195bool ecpg_store_result (const PGresult * results , int act_field ,
193196 const struct statement * stmt , struct variable * var );
194- bool ecpg_store_input (const int , const bool , const struct variable * , char * * , bool );
197+ bool ecpg_store_input (const int lineno , const bool force_indicator ,
198+ const struct variable * var ,
199+ char * * tobeinserted_p , bool quote );
195200void ecpg_free_params (struct statement * stmt , bool print );
196- bool ecpg_do_prologue (int , const int , const int , const char * , const bool ,
197- enum ECPG_statement_type , const char * , va_list ,
198- struct statement * * );
199- bool ecpg_build_params (struct statement * );
201+ bool ecpg_do_prologue (int lineno , const int compat ,
202+ const int force_indicator , const char * connection_name ,
203+ const bool questionmarks , enum ECPG_statement_type statement_type ,
204+ const char * query , va_list args ,
205+ struct statement * * stmt_out );
206+ bool ecpg_build_params (struct statement * stmt );
200207bool ecpg_autostart_transaction (struct statement * stmt );
201208bool ecpg_execute (struct statement * stmt );
202- bool ecpg_process_output (struct statement * , bool );
203- void ecpg_do_epilogue (struct statement * );
204- bool ecpg_do (const int , const int , const int , const char * , const bool ,
205- const int , const char * , va_list );
206-
207- bool ecpg_check_PQresult (PGresult * , int , PGconn * , enum COMPAT_MODE );
209+ bool ecpg_process_output (struct statement * stmt , bool clear_result );
210+ void ecpg_do_epilogue (struct statement * stmt );
211+ bool ecpg_do (const int lineno , const int compat ,
212+ const int force_indicator , const char * connection_name ,
213+ const bool questionmarks , const int st , const char * query ,
214+ va_list args );
215+
216+ bool ecpg_check_PQresult (PGresult * results , int lineno ,
217+ PGconn * connection , enum COMPAT_MODE compat );
208218void ecpg_raise (int line , int code , const char * sqlstate , const char * str );
209219void ecpg_raise_backend (int line , PGresult * result , PGconn * conn , int compat );
210- char * ecpg_prepared (const char * , struct connection * );
211- bool ecpg_deallocate_all_conn (int lineno , enum COMPAT_MODE c , struct connection * conn );
220+ char * ecpg_prepared (const char * name , struct connection * con );
221+ bool ecpg_deallocate_all_conn (int lineno , enum COMPAT_MODE c , struct connection * con );
212222void ecpg_log (const char * format ,...) pg_attribute_printf (1 , 2 );
213- bool ecpg_auto_prepare (int , const char * , const int , char * * , const char * );
214- bool ecpg_register_prepared_stmt (struct statement * );
223+ bool ecpg_auto_prepare (int lineno , const char * connection_name ,
224+ const int compat , char * * name , const char * query );
225+ bool ecpg_register_prepared_stmt (struct statement * stmt );
215226void ecpg_init_sqlca (struct sqlca_t * sqlca );
216227
217- struct sqlda_compat * ecpg_build_compat_sqlda (int , PGresult * , int , enum COMPAT_MODE );
218- void ecpg_set_compat_sqlda (int , struct sqlda_compat * * , const PGresult * , int , enum COMPAT_MODE );
219- struct sqlda_struct * ecpg_build_native_sqlda (int , PGresult * , int , enum COMPAT_MODE );
220- void ecpg_set_native_sqlda (int , struct sqlda_struct * * , const PGresult * , int , enum COMPAT_MODE );
228+ struct sqlda_compat * ecpg_build_compat_sqlda (int line , PGresult * res , int row ,
229+ enum COMPAT_MODE compat );
230+ void ecpg_set_compat_sqlda (int lineno , struct sqlda_compat * * _sqlda ,
231+ const PGresult * res , int row ,
232+ enum COMPAT_MODE compat );
233+ struct sqlda_struct * ecpg_build_native_sqlda (int line , PGresult * res , int row ,
234+ enum COMPAT_MODE compat );
235+ void ecpg_set_native_sqlda (int lineno , struct sqlda_struct * * _sqlda ,
236+ const PGresult * res , int row , enum COMPAT_MODE compat );
221237unsigned ecpg_hex_dec_len (unsigned srclen );
222238unsigned ecpg_hex_enc_len (unsigned srclen );
223239unsigned ecpg_hex_encode (const char * src , unsigned len , char * dst );
0 commit comments