diff options
author | Peter Eisentraut <peter_e@gmx.net> | 2009-01-15 11:52:55 +0000 |
---|---|---|
committer | Peter Eisentraut <peter_e@gmx.net> | 2009-01-15 11:52:55 +0000 |
commit | cb05ab81a857582161dd74cbfa91d4468e496cd1 (patch) | |
tree | d9808e4df13a70e2cb6f68fd09a059fa54170a7d /src/interfaces/ecpg/ecpglib/data.c | |
parent | cbb1358b18c88216a56de8847428d1bbcc51f280 (diff) | |
download | postgresql-cb05ab81a857582161dd74cbfa91d4468e496cd1.tar.gz postgresql-cb05ab81a857582161dd74cbfa91d4468e496cd1.zip |
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.
Diffstat (limited to 'src/interfaces/ecpg/ecpglib/data.c')
-rw-r--r-- | src/interfaces/ecpg/ecpglib/data.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/interfaces/ecpg/ecpglib/data.c b/src/interfaces/ecpg/ecpglib/data.c index 392ebdde773..9ec78a599dc 100644 --- a/src/interfaces/ecpg/ecpglib/data.c +++ b/src/interfaces/ecpg/ecpglib/data.c @@ -1,4 +1,4 @@ -/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/data.c,v 1.41 2008/05/16 15:20:03 petere Exp $ */ +/* $PostgreSQL: pgsql/src/interfaces/ecpg/ecpglib/data.c,v 1.42 2009/01/15 11:52:55 petere Exp $ */ #define POSTGRES_ECPG_INTERNAL #include "postgres_fe.h" @@ -60,7 +60,7 @@ ecpg_get_data(const PGresult *results, int act_tuple, int act_field, int lineno, else log_offset = offset; - ecpg_log("ecpg_get_data on line %d: RESULT: %s offset: %ld; array: %s\n", lineno, pval ? (binary ? _("BINARY") : pval) : _("EMPTY"), log_offset, isarray ? _("yes") : _("no")); + ecpg_log("ecpg_get_data on line %d: RESULT: %s offset: %ld; array: %s\n", lineno, pval ? (binary ? "BINARY" : pval) : "EMPTY", log_offset, isarray ? "yes" : "no"); /* We will have to decode the value */ @@ -360,7 +360,7 @@ ecpg_get_data(const PGresult *results, int act_tuple, int act_field, int lineno, else ecpg_raise(lineno, ECPG_CONVERT_BOOL, ECPG_SQLSTATE_DATATYPE_MISMATCH, - _("different size")); + NULL); break; } else if (pval[0] == 't' && pval[1] == '\0') @@ -372,7 +372,7 @@ ecpg_get_data(const PGresult *results, int act_tuple, int act_field, int lineno, else ecpg_raise(lineno, ECPG_CONVERT_BOOL, ECPG_SQLSTATE_DATATYPE_MISMATCH, - _("different size")); + NULL); break; } else if (pval[0] == '\0' && PQgetisnull(results, act_tuple, act_field)) |