Michael Meskes
2d3c691146
Fixed auto allocation for binary data types.
2009-02-02 16:14:06 +00:00
Peter Eisentraut
cb05ab81a8
NLS cleanup in ecpglib
...
Replace leftover instances of _() by ecpg_gettext(), the latter being the
correct way to refer to the library's message catalog, instead of the one of
the program using the library.
Drop NLS support for ecpg_log(), which is a debugging instrument similar to
elog() in the backend.
We cannot support NLS in the ecpg compatlib, because that requires
ecpg_gettext, which is in ecpglib, which is not a dependency of compatlib. It
doesn't seem worthwhile to worry about this, since the only translatable
string is "out of memory", and gettext probably won't be able to do much
without memory either.
Adjust messages to project style.
2009-01-15 11:52:55 +00:00
Peter Eisentraut
e1bdd07c3c
Add localization support to ecpg.
...
Author: Euler Taveira de Oliveira <euler@timbira.com>
2008-05-16 15:20:04 +00:00
Tom Lane
e04fa58dcd
Fix unportable usages of tolower(). On signed-char machines, it is necessary
...
to explicitly cast the output back to char before comparing it to a char
value, else we get the wrong result for high-bit-set characters. Found by
Rolf Jentsch. Also, fix several places where <ctype.h> functions were being
called without casting the argument to unsigned char; this is likewise
unportable, but we keep making that mistake :-(. These found by buildfarm
member salamander, which I will desperately miss if it ever goes belly-up.
2008-03-01 03:26:35 +00:00
Michael Meskes
fa0dc92fd8
- Fixed segfault in ecpg when using an array element.
...
- Free all memory in auto-prepare mode.
2008-02-07 11:09:13 +00:00
Michael Meskes
dbdc2e52a0
Re-enabled variables in fetch/move command.
2008-01-15 10:31:47 +00:00
Michael Meskes
149db6b6b7
Changed prototype for ECPGdo because some compilers don't like int/enum aliasing in there.
2008-01-13 11:53:16 +00:00
Bruce Momjian
fdf5a5efb7
pgindent run for 8.3.
2007-11-15 21:14:46 +00:00
Michael Meskes
7793c6ecca
Cleaned up ecpglib and renamed functions that do not need to be exported.
...
Created export list for ecpglib.
2007-10-03 11:11:12 +00:00
Michael Meskes
0c2eb200d6
ITAGAKI Takahiro <itagaki.takahiro@oss.ntt.co.jp> added thread-safe
...
descriptor handling
2007-10-02 09:50:00 +00:00
Michael Meskes
d49b20fbe6
Applied patch by ITAGAKI Takahiro <itagaki.takahiro@oss.ntt.co.jp> to get prepare thread-safe.
2007-09-26 10:57:01 +00:00
Michael Meskes
3e77c8c6c6
Removed superfluous ECPGfree() call.
2007-09-21 10:59:27 +00:00
Michael Meskes
635a0b9a86
- Finished major rewrite to use new protocol version
...
- Really prepare statements
- Added more regression tests
- Added auto-prepare mode
- Use '$n' for positional variables, '?' is still possible via ecpg option
- Cleaned up the sources a little bit
2007-08-14 10:01:54 +00:00
Michael Meskes
91411b6105
Fixed one memory leak in descriptor code.
...
Made sure ecpg deletes output file in case of an error.
2007-06-11 11:52:08 +00:00
Michael Meskes
c8577c6c7f
Inlined two functions to get rid of va_list problems on some archs.
2007-04-27 06:56:11 +00:00
Michael Meskes
ddcb5bbf76
- Added patch by Magnus Hagander <magnus@hagander.net> to use native
...
win32 threads.
- Fixed regression tests to run threading tests.
2007-03-29 12:02:24 +00:00
Michael Meskes
153affd058
Fixed multibyte handling as reported by <harada.toshi@oss.ntt.co.jp>.
2007-02-11 15:18:17 +00:00
Michael Meskes
fc8115d42f
Cleaned up va_list handling. Hopefully this now works on all archs.
2007-02-02 08:58:23 +00:00
Bruce Momjian
f99a569a2e
pgindent run for 8.2.
2006-10-04 00:30:14 +00:00
Michael Meskes
9bade3ff84
Replaced double-quote-fix with a hopefully better version.
...
Use initializer string length as size for character strings.
Added ecpg_config.h file that is created via configure.
2006-08-23 12:01:53 +00:00
Michael Meskes
54f5527606
Descriptor values were quoted twice.
...
Fixed some regression test problems.
2006-08-22 12:46:18 +00:00
Michael Meskes
46d61eb218
Fixed a buffer overrun that was masked on Linux systems.
2006-08-18 16:30:53 +00:00
Michael Meskes
e6e61afe16
Fixed some memory bugs that somehow reappeared.
...
Also fixed a new Coverity report.
2006-08-09 09:08:32 +00:00
Michael Meskes
79a1a2ec6b
Cleaned up log output a little bit more.
2006-08-08 15:30:39 +00:00
Michael Meskes
1fa6be6f69
ynced parser and keyword list.
...
Implemented EXEC SQL UNDEF.
Applied first version of the regression test patch by Joachim Wieland <joe@mcknight.de>.
2006-08-02 13:43:23 +00:00
Michael Meskes
76475a7eb5
Variables should be free'ed only once.
2006-07-28 11:49:36 +00:00
Michael Meskes
a27cb17788
Removed superfluous comment
2006-07-28 10:12:56 +00:00
Michael Meskes
72ba3cb50f
Added more SoC changes by Joachim Wieland <joe@mcknight.de>:
...
- SHOW statement puts result into a variable
- COPY TO STDOUT works
2006-07-28 09:08:01 +00:00
Tom Lane
ae643747b1
Fix a passel of recently-committed violations of the rule 'thou shalt
...
have no other gods before c.h'. Also remove some demonstrably redundant
#include lines, mostly of <errno.h> which was added to c.h years ago.
2006-07-14 05:28:29 +00:00
Michael Meskes
956cbeb7ef
Fixed remaining Coverity bugs.
2006-07-05 10:49:56 +00:00
Michael Meskes
ea9ec780ed
Added some more coverity report patches send in by Joachim Wieland <joe@mcknight.de>.
2006-06-26 09:20:09 +00:00
Michael Meskes
17bab8c3fe
Moved some free() calls that coverity correctly complains about.
2006-06-25 09:38:40 +00:00
Michael Meskes
3f9aace723
Added some more coverity report patches send in by Martijn van Oosterhout <kleptog@svana.org>.
2006-06-21 11:38:07 +00:00
Michael Meskes
a829da152c
Added fixed from the coverity report send in by Joachim Wieland <joe@mcknight.de>
...
Added missing error handling in a few functions in ecpglib
2006-06-21 10:24:41 +00:00
Bruce Momjian
7a846ecc00
Use E'' strings internally only when standard_conforming_strings =
...
'off'. This allows pg_dump output with standard_conforming_strings =
'on' to generate proper strings that can be loaded into other databases
without the backslash doubling we typically do. I have added the
dumping of the standard_conforming_strings value to pg_dump.
I also added standard backslash handling for plpgsql.
2006-05-26 23:48:54 +00:00
Michael Meskes
524d65d459
Fixed memory leak bugs found by Martijn Oosterhout.
2006-04-24 09:45:22 +00:00
Michael Meskes
150131d9d9
- Made several variables "const char *" instead of "char *" as proposed by Qingqing Zhou <zhouqq@cs.toronto.edu>.
...
- Replaced all strdup() calls by ECPGstrdup().
- Set ecpg library version to 5.2.
- Set ecpg version to 4.2.1.
2005-11-30 12:49:49 +00:00
Bruce Momjian
1dc3498251
Standard pgindent run for 8.1.
2005-10-15 02:49:52 +00:00
Bruce Momjian
8a79451152
I have to admit that I got the case of the preprocessor symbol on amd64
...
wrong. __AMD64__ is not defined, __amd64__ is.
Christof Petig
2005-07-04 19:05:45 +00:00
Bruce Momjian
74b49a8129
Add E'' to internally created SQL strings that contain backslashes.
...
Improve code clarity by using macros for E'' processing.
2005-07-02 17:01:59 +00:00
Michael Meskes
2d5d691d15
- Fixed memory leak in ecpglib by adding some missing free() commands.
...
- Added patch by Gavin Scott <gavin@planetacetech.com> for Intel 64bit hardware.
2005-06-02 12:35:11 +00:00
Michael Meskes
1f418555cf
Added patch by Christof Petig <christof@petig-baender.de> to work around gcc bug on powerpc and amd64.
2005-03-18 10:00:43 +00:00
Bruce Momjian
b6b71b85bc
Pgindent run for 8.0.
2004-08-29 05:07:03 +00:00
Michael Meskes
073f7312a4
- Fixed indicator in SET DESCRIPTOR.
...
- Added special handling of descriptor header information.
- Some code cleanup.
2004-07-05 09:45:54 +00:00
Michael Meskes
8715789928
Made sure SET DESCRIPTOR accepts all data types including constants.
2004-07-04 15:02:24 +00:00
Michael Meskes
90326c01c9
Added SET DESCRIPTOR command.
...
Note that this still has some bugs. The functionality is there though, it's just a matter of fixing the bugs now.
Cleaned up error handling in preprocessor.
2004-06-30 15:01:58 +00:00
Michael Meskes
03ad5da8f8
- Only use typedefs inside their scope.
...
- Variables that are out of scope, were not removed all the time.
- Make a varchar NULL set everything to 0 when not using indicators.
- Synced parser.
2004-06-27 12:28:42 +00:00
Michael Meskes
e845adf31f
- Fixed bug in adjust_informix that treated arrays as simple variables.
...
- Synced parser again.
- Synced lexer.
2004-05-05 15:03:04 +00:00
Michael Meskes
6ccfc4f430
- Issue a warning if a cursor is declared but not opened.
...
- Fixed prototype for ECPGprepared_statement to not moan about "const char"
- Fixed parsing of nested structures.
- Added option to parse header files.
2004-01-28 09:52:14 +00:00
Neil Conway
192ad63bd7
More janitorial work: remove the explicit casting of NULL literals to a
...
pointer type when it is not necessary to do so.
For future reference, casting NULL to a pointer type is only necessary
when (a) invoking a function AND either (b) the function has no prototype
OR (c) the function is a varargs function.
2004-01-07 18:56:30 +00:00