aboutsummaryrefslogtreecommitdiff
path: root/src/interfaces/ecpg
diff options
context:
space:
mode:
authorPeter Eisentraut <peter_e@gmx.net>2010-11-23 22:27:50 +0200
committerPeter Eisentraut <peter_e@gmx.net>2010-11-23 22:34:55 +0200
commitfc946c39aeacdff7df60c83fca6582985e8546c8 (patch)
tree866145f64c09c0673a4aa3d3a2f5647f0b7afc45 /src/interfaces/ecpg
parent44475e782f4674d257b9e5c1a3930218a4b4deea (diff)
downloadpostgresql-fc946c39aeacdff7df60c83fca6582985e8546c8.tar.gz
postgresql-fc946c39aeacdff7df60c83fca6582985e8546c8.zip
Remove useless whitespace at end of lines
Diffstat (limited to 'src/interfaces/ecpg')
-rw-r--r--src/interfaces/ecpg/README.dynSQL2
-rw-r--r--src/interfaces/ecpg/ecpglib/prepare.c2
-rw-r--r--src/interfaces/ecpg/preproc/Makefile2
-rwxr-xr-xsrc/interfaces/ecpg/preproc/check_rules.pl4
-rw-r--r--src/interfaces/ecpg/preproc/ecpg.addons4
-rw-r--r--src/interfaces/ecpg/preproc/ecpg.header2
-rw-r--r--src/interfaces/ecpg/preproc/ecpg.tokens4
-rw-r--r--src/interfaces/ecpg/preproc/ecpg.trailer14
-rw-r--r--src/interfaces/ecpg/preproc/ecpg.type2
-rw-r--r--src/interfaces/ecpg/preproc/parse.pl16
-rw-r--r--src/interfaces/ecpg/preproc/pgc.l44
-rw-r--r--src/interfaces/ecpg/test/Makefile.regress4
-rw-r--r--src/interfaces/ecpg/test/compat_informix/describe.pgc2
-rw-r--r--src/interfaces/ecpg/test/compat_informix/sqlda.pgc2
-rw-r--r--src/interfaces/ecpg/test/compat_informix/test_informix.pgc2
-rw-r--r--src/interfaces/ecpg/test/compat_informix/test_informix2.pgc6
-rw-r--r--src/interfaces/ecpg/test/expected/compat_informix-describe.c2
-rw-r--r--src/interfaces/ecpg/test/expected/compat_informix-sqlda.c2
-rw-r--r--src/interfaces/ecpg/test/expected/compat_informix-test_informix.c2
-rw-r--r--src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c4
-rw-r--r--src/interfaces/ecpg/test/expected/pgtypeslib-dt_test.c12
-rw-r--r--src/interfaces/ecpg/test/expected/preproc-array_of_struct.c2
-rw-r--r--src/interfaces/ecpg/test/expected/preproc-cursor.c2
-rw-r--r--src/interfaces/ecpg/test/expected/preproc-init.c4
-rw-r--r--src/interfaces/ecpg/test/expected/preproc-outofscope.c2
-rw-r--r--src/interfaces/ecpg/test/expected/preproc-variable.c2
-rw-r--r--src/interfaces/ecpg/test/expected/preproc-whenever.c2
-rw-r--r--src/interfaces/ecpg/test/expected/sql-array.c4
-rw-r--r--src/interfaces/ecpg/test/expected/sql-code100.c10
-rw-r--r--src/interfaces/ecpg/test/expected/sql-describe.c2
-rw-r--r--src/interfaces/ecpg/test/expected/sql-dynalloc.c16
-rw-r--r--src/interfaces/ecpg/test/expected/sql-dynalloc2.c4
-rw-r--r--src/interfaces/ecpg/test/expected/sql-fetch.c2
-rw-r--r--src/interfaces/ecpg/test/expected/sql-sqlda.c2
-rw-r--r--src/interfaces/ecpg/test/pgtypeslib/dt_test.pgc12
-rw-r--r--src/interfaces/ecpg/test/preproc/array_of_struct.pgc2
-rw-r--r--src/interfaces/ecpg/test/preproc/cursor.pgc2
-rw-r--r--src/interfaces/ecpg/test/preproc/init.pgc4
-rw-r--r--src/interfaces/ecpg/test/preproc/outofscope.pgc2
-rw-r--r--src/interfaces/ecpg/test/preproc/variable.pgc2
-rw-r--r--src/interfaces/ecpg/test/preproc/whenever.pgc2
-rw-r--r--src/interfaces/ecpg/test/sql/Makefile2
-rw-r--r--src/interfaces/ecpg/test/sql/array.pgc4
-rw-r--r--src/interfaces/ecpg/test/sql/code100.pgc12
-rw-r--r--src/interfaces/ecpg/test/sql/describe.pgc2
-rw-r--r--src/interfaces/ecpg/test/sql/dynalloc.pgc16
-rw-r--r--src/interfaces/ecpg/test/sql/dynalloc2.pgc4
-rw-r--r--src/interfaces/ecpg/test/sql/fetch.pgc2
-rw-r--r--src/interfaces/ecpg/test/sql/sqlda.pgc2
49 files changed, 129 insertions, 129 deletions
diff --git a/src/interfaces/ecpg/README.dynSQL b/src/interfaces/ecpg/README.dynSQL
index dcb263e9f64..e1d1507fd07 100644
--- a/src/interfaces/ecpg/README.dynSQL
+++ b/src/interfaces/ecpg/README.dynSQL
@@ -3,7 +3,7 @@ src/interfaces/ecpg/README.dynSQL
descriptor statements have the following shortcomings
- input descriptors (USING DESCRIPTOR <name>) are not supported
-
+
Reason: to fully support dynamic SQL the frontend/backend communication
should change to recognize input parameters.
Since this is not likely to happen in the near future and you
diff --git a/src/interfaces/ecpg/ecpglib/prepare.c b/src/interfaces/ecpg/ecpglib/prepare.c
index 90288d343bf..0296d925b9d 100644
--- a/src/interfaces/ecpg/ecpglib/prepare.c
+++ b/src/interfaces/ecpg/ecpglib/prepare.c
@@ -164,7 +164,7 @@ ECPGprepare(int lineno, const char *connection_name, const bool questionmarks, c
struct prepared_statement *this,
*prev;
- (void) questionmarks; /* quiet the compiler */
+ (void) questionmarks; /* quiet the compiler */
con = ecpg_get_connection(connection_name);
if (!ecpg_init(con, connection_name, lineno))
diff --git a/src/interfaces/ecpg/preproc/Makefile b/src/interfaces/ecpg/preproc/Makefile
index e8a6916faa8..4c8f8d699d6 100644
--- a/src/interfaces/ecpg/preproc/Makefile
+++ b/src/interfaces/ecpg/preproc/Makefile
@@ -58,7 +58,7 @@ else
endif
preproc.y: ../../../backend/parser/gram.y parse.pl ecpg.addons ecpg.header ecpg.tokens ecpg.trailer ecpg.type
- $(PERL) $(srcdir)/parse.pl $(srcdir) < $< > $@
+ $(PERL) $(srcdir)/parse.pl $(srcdir) < $< > $@
$(PERL) $(srcdir)/check_rules.pl $(srcdir) $<
ecpg_keywords.o c_keywords.o keywords.o preproc.o parser.o: preproc.h
diff --git a/src/interfaces/ecpg/preproc/check_rules.pl b/src/interfaces/ecpg/preproc/check_rules.pl
index 7dc6ca46fb9..3a796493d5f 100755
--- a/src/interfaces/ecpg/preproc/check_rules.pl
+++ b/src/interfaces/ecpg/preproc/check_rules.pl
@@ -102,7 +102,7 @@ while (<GRAM>) {
$block = $block . $arr[$fieldIndexer];
}
}
-}
+}
close GRAM;
@@ -113,7 +113,7 @@ line: while (<ECPG>) {
@Fld = split(' ', $_, -1);
if (!/^ECPG:/) {
- next line;
+ next line;
}
if ($found{$Fld[2]} ne 'found') {
diff --git a/src/interfaces/ecpg/preproc/ecpg.addons b/src/interfaces/ecpg/preproc/ecpg.addons
index 3b74ba0a4e4..3a8c2dca10b 100644
--- a/src/interfaces/ecpg/preproc/ecpg.addons
+++ b/src/interfaces/ecpg/preproc/ecpg.addons
@@ -40,7 +40,7 @@ ECPG: stmtPrepareStmt block
{
if ($1.type == NULL || strlen($1.type) == 0)
output_prepare_statement($1.name, $1.stmt);
- else
+ else
output_statement(cat_str(5, make_str("prepare"), $1.name, $1.type, make_str("as"), $1.stmt), 0, ECPGst_normal);
}
ECPG: stmtTransactionStmt block
@@ -109,7 +109,7 @@ ECPG: stmtViewStmt rule
if (!strcmp($1, "all"))
fprintf(yyout, "{ ECPGdeallocate_all(__LINE__, %d, %s);", compat, con);
- else if ($1[0] == ':')
+ else if ($1[0] == ':')
fprintf(yyout, "{ ECPGdeallocate(__LINE__, %d, %s, %s);", compat, con, $1+1);
else
fprintf(yyout, "{ ECPGdeallocate(__LINE__, %d, %s, \"%s\");", compat, con, $1);
diff --git a/src/interfaces/ecpg/preproc/ecpg.header b/src/interfaces/ecpg/preproc/ecpg.header
index 54979e987c6..3f6ffd9c7b1 100644
--- a/src/interfaces/ecpg/preproc/ecpg.header
+++ b/src/interfaces/ecpg/preproc/ecpg.header
@@ -103,7 +103,7 @@ mmerror(int error_code, enum errortype type, const char *error, ...)
fclose(yyin);
if (yyout)
fclose(yyout);
-
+
if (strcmp(output_filename, "-") != 0 && unlink(output_filename) != 0)
fprintf(stderr, _("could not remove output file \"%s\"\n"), output_filename);
exit(error_code);
diff --git a/src/interfaces/ecpg/preproc/ecpg.tokens b/src/interfaces/ecpg/preproc/ecpg.tokens
index c396b552f92..b55138a3167 100644
--- a/src/interfaces/ecpg/preproc/ecpg.tokens
+++ b/src/interfaces/ecpg/preproc/ecpg.tokens
@@ -3,7 +3,7 @@
/* special embedded SQL tokens */
%token SQL_ALLOCATE SQL_AUTOCOMMIT SQL_BOOL SQL_BREAK
SQL_CALL SQL_CARDINALITY SQL_CONNECT
- SQL_COUNT
+ SQL_COUNT
SQL_DATETIME_INTERVAL_CODE
SQL_DATETIME_INTERVAL_PRECISION SQL_DESCRIBE
SQL_DESCRIPTOR SQL_DISCONNECT SQL_FOUND
@@ -23,5 +23,5 @@
S_STATIC S_SUB S_VOLATILE
S_TYPEDEF
-%token CSTRING CVARIABLE CPP_LINE IP
+%token CSTRING CVARIABLE CPP_LINE IP
%token DOLCONST ECONST NCONST UCONST UIDENT
diff --git a/src/interfaces/ecpg/preproc/ecpg.trailer b/src/interfaces/ecpg/preproc/ecpg.trailer
index 2eaef25c534..e80fece810c 100644
--- a/src/interfaces/ecpg/preproc/ecpg.trailer
+++ b/src/interfaces/ecpg/preproc/ecpg.trailer
@@ -70,7 +70,7 @@ connection_target: opt_database_name opt_server opt_port
/* old style: dbname[@server][:port] */
if (strlen($2) > 0 && *($2) != '@')
mmerror(PARSE_ERROR, ET_ERROR, "expected \"@\", found \"%s\"", $2);
-
+
/* C strings need to be handled differently */
if ($1[0] == '\"')
$$ = $1;
@@ -241,7 +241,7 @@ opt_options: Op connect_options
| /*EMPTY*/ { $$ = EMPTY; }
;
-connect_options: ColId opt_opt_value
+connect_options: ColId opt_opt_value
{ $$ = make2_str($1, $2); }
| ColId opt_opt_value Op connect_options
{
@@ -347,7 +347,7 @@ ECPGCursorStmt: DECLARE cursor_name cursor_options CURSOR opt_hold FOR prepared
;
ECPGExecuteImmediateStmt: EXECUTE IMMEDIATE execstring
- {
+ {
/* execute immediate means prepare the statement and
* immediately execute it */
$$ = $3;
@@ -631,7 +631,7 @@ var_type: simple_type
$$.type_index = this->type->type_index;
if (this->type->type_sizeof && strlen(this->type->type_sizeof) != 0)
$$.type_sizeof = this->type->type_sizeof;
- else
+ else
$$.type_sizeof = cat_str(3, make_str("sizeof("), mm_strdup(this->name), make_str(")"));
struct_member_list[struct_level] = ECPGstruct_member_dup(this->struct_member_list);
@@ -862,7 +862,7 @@ variable: opt_pointer ECPGColLabel opt_array_bounds opt_bit_field opt_initialize
type = ECPGmake_simple_type(actual_type[struct_level].type_enum, length, varchar_counter);
else
type = ECPGmake_array_type(ECPGmake_simple_type(actual_type[struct_level].type_enum, length, varchar_counter), dimension);
-
+
if (strcmp(dimension, "0") == 0 || abs(atoi(dimension)) == 1)
*dim = '\0';
else
@@ -1037,7 +1037,7 @@ UsingValue: UsingConst
}
| civar { $$ = EMPTY; }
| civarind { $$ = EMPTY; }
- ;
+ ;
UsingConst: Iconst { $$ = $1; }
| '+' Iconst { $$ = cat_str(2, make_str("+"), $2); }
@@ -1857,7 +1857,7 @@ execute_rest: /* EMPTY */ { $$ = EMPTY; }
| ecpg_into ecpg_using { $$ = EMPTY; }
| ecpg_using { $$ = EMPTY; }
| ecpg_into { $$ = EMPTY; }
- ;
+ ;
ecpg_into: INTO into_list { $$ = EMPTY; }
| into_descriptor { $$ = $1; }
diff --git a/src/interfaces/ecpg/preproc/ecpg.type b/src/interfaces/ecpg/preproc/ecpg.type
index 831c4c3b200..ac6aa000ac2 100644
--- a/src/interfaces/ecpg/preproc/ecpg.type
+++ b/src/interfaces/ecpg/preproc/ecpg.type
@@ -113,7 +113,7 @@
%type <str> variable
%type <str> variable_declarations
%type <str> variable_list
-%type <str> vt_declarations
+%type <str> vt_declarations
%type <str> Op
%type <str> IntConstVar
diff --git a/src/interfaces/ecpg/preproc/parse.pl b/src/interfaces/ecpg/preproc/parse.pl
index f3c757e8931..b765a583056 100644
--- a/src/interfaces/ecpg/preproc/parse.pl
+++ b/src/interfaces/ecpg/preproc/parse.pl
@@ -93,7 +93,7 @@ line: while (<>) {
chomp; # strip record separator
@Fld = split(' ', $_, -1);
- # Dump the action for a rule -
+ # Dump the action for a rule -
# mode indicates if we are processing the 'stmt:' rule (mode==0 means normal, mode==1 means stmt:)
# flds are the fields to use. These may start with a '$' - in which case they are the result of a previous non-terminal
# if they dont start with a '$' then they are token name
@@ -235,8 +235,8 @@ line: while (<>) {
if ($replace_token{$arr[$fieldIndexer]}) {
$arr[$fieldIndexer] = $replace_token{$arr[$fieldIndexer]};
}
-
- # Are we looking at a declaration of a non-terminal ?
+
+ # Are we looking at a declaration of a non-terminal ?
if (($arr[$fieldIndexer] =~ '[A-Za-z0-9]+:') || $arr[$fieldIndexer + 1] eq ':') {
$non_term_id = $arr[$fieldIndexer];
$s = ':', $non_term_id =~ s/$s//g;
@@ -253,7 +253,7 @@ line: while (<>) {
$copymode = 'on';
}
$line = $line . ' ' . $arr[$fieldIndexer];
- # Do we have the : attached already ?
+ # Do we have the : attached already ?
# If yes, we'll have already printed the ':'
if (!($arr[$fieldIndexer] =~ '[A-Za-z0-9]+:')) {
# Consume the ':' which is next...
@@ -261,7 +261,7 @@ line: while (<>) {
$fieldIndexer++;
}
- # Special mode?
+ # Special mode?
if ($non_term_id eq 'stmt') {
$stmt_mode = 1;
}
@@ -380,7 +380,7 @@ sub dump {
sub dump_fields {
local($mode, *flds, $len, $ln) = @_;
if ($mode == 0) {
- #Normal
+ #Normal
&add_to_buffer('rules', $ln);
if ($feature_not_supported == 1) {
# we found an unsupported feature, but we have to
@@ -393,7 +393,7 @@ sub dump_fields {
}
if ($len == 0) {
- # We have no fields ?
+ # We have no fields ?
&add_to_buffer('rules', " \$\$=EMPTY; }");
}
else {
@@ -418,7 +418,7 @@ sub dump_fields {
}
}
- # So - how many fields did we end up with ?
+ # So - how many fields did we end up with ?
if ($cnt == 1) {
# Straight assignement
$str = " \$\$ = " . $flds_new{0} . ';';
diff --git a/src/interfaces/ecpg/preproc/pgc.l b/src/interfaces/ecpg/preproc/pgc.l
index 05febb556da..b7e46866f72 100644
--- a/src/interfaces/ecpg/preproc/pgc.l
+++ b/src/interfaces/ecpg/preproc/pgc.l
@@ -58,8 +58,8 @@ static bool isinformixdefine(void);
char *token_start;
int state_before;
-struct _yy_buffer
-{
+struct _yy_buffer
+{
YY_BUFFER_STATE buffer;
long lineno;
char *filename;
@@ -71,7 +71,7 @@ static char *old;
#define MAX_NESTED_IF 128
static short preproc_tos;
static short ifcond;
-static struct _if_value
+static struct _if_value
{
short condition;
short else_branch;
@@ -87,7 +87,7 @@ static struct _if_value
%option yylineno
-%x C SQL incl def def_ident undef
+%x C SQL incl def def_ident undef
/*
* OK, here is a short description of lex/flex rules behavior.
@@ -518,7 +518,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
/* throw back all but the initial "$" */
yyless(1);
/* and treat it as {other} */
- return yytext[0];
+ return yytext[0];
}
<SQL>{dolqdelim} {
token_start = yytext;
@@ -737,7 +737,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
}
<SQL>{identifier} {
const ScanKeyword *keyword;
-
+
if (!isdefine())
{
/* Is it an SQL/ECPG keyword? */
@@ -764,7 +764,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
}
<SQL>{other} { return yytext[0]; }
<C>{exec_sql} { BEGIN(SQL); return SQL_START; }
-<C>{informix_special} {
+<C>{informix_special} {
/* are we simulating Informix? */
if (INFORMIX_MODE)
{
@@ -939,7 +939,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
yyterminate();
}
<C>{exec_sql}{include}{space}* { BEGIN(incl); }
-<C>{informix_special}{include}{space}* {
+<C>{informix_special}{include}{space}* {
/* are we simulating Informix? */
if (INFORMIX_MODE)
{
@@ -952,7 +952,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
}
}
<C,xskip>{exec_sql}{ifdef}{space}* { ifcond = TRUE; BEGIN(xcond); }
-<C,xskip>{informix_special}{ifdef}{space}* {
+<C,xskip>{informix_special}{ifdef}{space}* {
/* are we simulating Informix? */
if (INFORMIX_MODE)
{
@@ -966,7 +966,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
}
}
<C,xskip>{exec_sql}{ifndef}{space}* { ifcond = FALSE; BEGIN(xcond); }
-<C,xskip>{informix_special}{ifndef}{space}* {
+<C,xskip>{informix_special}{ifndef}{space}* {
/* are we simulating Informix? */
if (INFORMIX_MODE)
{
@@ -990,7 +990,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
ifcond = TRUE; BEGIN(xcond);
}
-<C,xskip>{informix_special}{elif}{space}* {
+<C,xskip>{informix_special}{elif}{space}* {
/* are we simulating Informix? */
if (INFORMIX_MODE)
{
@@ -1089,7 +1089,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
<xcond>{identifier}{space}*";" {
if (preproc_tos >= MAX_NESTED_IF-1)
mmerror(PARSE_ERROR, ET_FATAL, "too many nested EXEC SQL IFDEF conditions");
- else
+ else
{
struct _defines *defptr;
unsigned int i;
@@ -1132,7 +1132,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
<def_ident>{other}|\n {
mmerror(PARSE_ERROR, ET_FATAL, "missing identifier in EXEC SQL DEFINE command");
yyterminate();
- }
+ }
<def>{space}*";" {
struct _defines *ptr, *this;
@@ -1170,7 +1170,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
<<EOF>> {
if (yy_buffer == NULL)
{
- if ( preproc_tos > 0 )
+ if ( preproc_tos > 0 )
{
preproc_tos = 0;
mmerror(PARSE_ERROR, ET_FATAL, "missing \"EXEC SQL ENDIF;\"");
@@ -1189,7 +1189,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
ptr->used = NULL;
break;
}
-
+
if (yyin != NULL)
fclose(yyin);
@@ -1209,7 +1209,7 @@ cppline {space}*#([^i][A-Za-z]*|{if}|{ifdef}|{ifndef}|{import})(.*\\{space})*.
if (i != 0)
output_line_number();
-
+
}
}
<INITIAL>{other}|\n { mmerror(PARSE_ERROR, ET_FATAL, "internal error: unreachable state; please report this to <pgsql-bugs@postgresql.org>"); }
@@ -1244,7 +1244,7 @@ addlit(char *ytext, int yleng)
/* enlarge buffer if needed */
if ((literallen+yleng) >= literalalloc)
{
- do
+ do
literalalloc *= 2;
while ((literallen+yleng) >= literalalloc);
literalbuf = (char *) realloc(literalbuf, literalalloc);
@@ -1290,7 +1290,7 @@ parse_include(void)
/*
* skip the ";" if there is one and trailing whitespace. Note that
- * yytext contains at least one non-space character plus the ";"
+ * yytext contains at least one non-space character plus the ";"
*/
for (i = strlen(yytext)-2;
i > 0 && ecpg_isspace(yytext[i]);
@@ -1301,7 +1301,7 @@ parse_include(void)
i--;
yytext[i+1] = '\0';
-
+
yyin = NULL;
/* If file name is enclosed in '"' remove these and look only in '.' */
@@ -1311,7 +1311,7 @@ parse_include(void)
{
yytext[i] = '\0';
memmove(yytext, yytext+1, strlen(yytext));
-
+
strncpy(inc_file, yytext, sizeof(inc_file));
yyin = fopen(inc_file, "r");
if (!yyin)
@@ -1322,7 +1322,7 @@ parse_include(void)
yyin = fopen(inc_file, "r");
}
}
-
+
}
else
{
@@ -1331,7 +1331,7 @@ parse_include(void)
yytext[i] = '\0';
memmove(yytext, yytext+1, strlen(yytext));
}
-
+
for (ip = include_paths; yyin == NULL && ip != NULL; ip = ip->next)
{
if (strlen(ip->path) + strlen(yytext) + 3 > MAXPGPATH)
diff --git a/src/interfaces/ecpg/test/Makefile.regress b/src/interfaces/ecpg/test/Makefile.regress
index df792fd2380..b2417081ee0 100644
--- a/src/interfaces/ecpg/test/Makefile.regress
+++ b/src/interfaces/ecpg/test/Makefile.regress
@@ -1,6 +1,6 @@
override CPPFLAGS := -I../../include -I$(top_srcdir)/src/interfaces/ecpg/include \
- -I$(libpq_srcdir) $(CPPFLAGS)
-override CFLAGS += $(PTHREAD_CFLAGS)
+ -I$(libpq_srcdir) $(CPPFLAGS)
+override CFLAGS += $(PTHREAD_CFLAGS)
override LDFLAGS := -L../../ecpglib -L../../pgtypeslib $(filter-out -l%, $(libpq)) $(LDFLAGS)
override LIBS := -lecpg -lpgtypes $(filter -l%, $(libpq)) $(LIBS) $(PTHREAD_LIBS)
diff --git a/src/interfaces/ecpg/test/compat_informix/describe.pgc b/src/interfaces/ecpg/test/compat_informix/describe.pgc
index b0f9a3d8f2b..1836ac3843d 100644
--- a/src/interfaces/ecpg/test/compat_informix/describe.pgc
+++ b/src/interfaces/ecpg/test/compat_informix/describe.pgc
@@ -192,7 +192,7 @@ exec sql end declare section;
strcpy(msg, "commit");
exec sql commit;
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
exec sql disconnect;
return (0);
diff --git a/src/interfaces/ecpg/test/compat_informix/sqlda.pgc b/src/interfaces/ecpg/test/compat_informix/sqlda.pgc
index 8490d061648..e1142d2b220 100644
--- a/src/interfaces/ecpg/test/compat_informix/sqlda.pgc
+++ b/src/interfaces/ecpg/test/compat_informix/sqlda.pgc
@@ -106,7 +106,7 @@ exec sql end declare section;
while (1)
{
strcpy(msg, "fetch");
- exec sql fetch 1 from mycur1 into descriptor outp_sqlda;
+ exec sql fetch 1 from mycur1 into descriptor outp_sqlda;
printf("FETCH RECORD %d\n", ++rec);
dump_sqlda(outp_sqlda);
diff --git a/src/interfaces/ecpg/test/compat_informix/test_informix.pgc b/src/interfaces/ecpg/test/compat_informix/test_informix.pgc
index e1cfd25a3b5..8b7692b0fdd 100644
--- a/src/interfaces/ecpg/test/compat_informix/test_informix.pgc
+++ b/src/interfaces/ecpg/test/compat_informix/test_informix.pgc
@@ -11,7 +11,7 @@ static void dosqlprint(void) {
int main(void)
{
- $int i = 14;
+ $int i = 14;
$decimal j, m, n;
$string c[10];
diff --git a/src/interfaces/ecpg/test/compat_informix/test_informix2.pgc b/src/interfaces/ecpg/test/compat_informix/test_informix2.pgc
index 9b324e25e87..0e8f1f0f0b4 100644
--- a/src/interfaces/ecpg/test/compat_informix/test_informix2.pgc
+++ b/src/interfaces/ecpg/test/compat_informix/test_informix2.pgc
@@ -67,8 +67,8 @@ int main(void)
EXEC SQL create table history (customerid integer, timestamp timestamp without time zone, action_taken char(5), narrative varchar(100));
sql_check("main", "create", 0);
-
- EXEC SQL insert into history
+
+ EXEC SQL insert into history
(customerid, timestamp, action_taken, narrative)
values(1, '2003-05-07 13:28:34 CEST', 'test', 'test');
sql_check("main", "insert", 0);
@@ -96,7 +96,7 @@ int main(void)
(customerid, timestamp, action_taken, narrative)
values(:c, :e, 'test', 'test');
sql_check("main", "update", 0);
-
+
EXEC SQL commit;
EXEC SQL drop table history;
diff --git a/src/interfaces/ecpg/test/expected/compat_informix-describe.c b/src/interfaces/ecpg/test/expected/compat_informix-describe.c
index 6aa534f5d67..b4e1b47066a 100644
--- a/src/interfaces/ecpg/test/expected/compat_informix-describe.c
+++ b/src/interfaces/ecpg/test/expected/compat_informix-describe.c
@@ -455,7 +455,7 @@ if (sqlca.sqlcode < 0) exit (1);}
#line 193 "describe.pgc"
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
{ ECPGdisconnect(__LINE__, "CURRENT");
#line 196 "describe.pgc"
diff --git a/src/interfaces/ecpg/test/expected/compat_informix-sqlda.c b/src/interfaces/ecpg/test/expected/compat_informix-sqlda.c
index 647f677c14b..a013be99aa2 100644
--- a/src/interfaces/ecpg/test/expected/compat_informix-sqlda.c
+++ b/src/interfaces/ecpg/test/expected/compat_informix-sqlda.c
@@ -268,7 +268,7 @@ if (sqlca.sqlcode == ECPG_NOT_FOUND) break;
if (sqlca.sqlcode < 0) exit (1);}
#line 109 "sqlda.pgc"
-
+
printf("FETCH RECORD %d\n", ++rec);
dump_sqlda(outp_sqlda);
diff --git a/src/interfaces/ecpg/test/expected/compat_informix-test_informix.c b/src/interfaces/ecpg/test/expected/compat_informix-test_informix.c
index 4cc6e3d7132..d357c77a436 100644
--- a/src/interfaces/ecpg/test/expected/compat_informix-test_informix.c
+++ b/src/interfaces/ecpg/test/expected/compat_informix-test_informix.c
@@ -36,7 +36,7 @@ int main(void)
int i = 14 ;
#line 14 "test_informix.pgc"
-
+
#line 15 "test_informix.pgc"
decimal j , m , n ;
diff --git a/src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c b/src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c
index 2f8ee74971a..c1a48911914 100644
--- a/src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c
+++ b/src/interfaces/ecpg/test/expected/compat_informix-test_informix2.c
@@ -193,7 +193,7 @@ if (sqlca.sqlcode < 0) sqlprint();}
#line 68 "test_informix2.pgc"
sql_check("main", "create", 0);
-
+
{ ECPGdo(__LINE__, 1, 1, NULL, 0, ECPGst_normal, "insert into history ( customerid , timestamp , action_taken , narrative ) values ( 1 , '2003-05-07 13:28:34 CEST' , 'test' , 'test' )", ECPGt_EOIT, ECPGt_EORT);
#line 73 "test_informix2.pgc"
@@ -244,7 +244,7 @@ if (sqlca.sqlcode < 0) sqlprint();}
#line 97 "test_informix2.pgc"
sql_check("main", "update", 0);
-
+
{ ECPGtrans(__LINE__, NULL, "commit");
#line 100 "test_informix2.pgc"
diff --git a/src/interfaces/ecpg/test/expected/pgtypeslib-dt_test.c b/src/interfaces/ecpg/test/expected/pgtypeslib-dt_test.c
index 58d11e8e7e1..648b648e219 100644
--- a/src/interfaces/ecpg/test/expected/pgtypeslib-dt_test.c
+++ b/src/interfaces/ecpg/test/expected/pgtypeslib-dt_test.c
@@ -55,17 +55,17 @@ main(void)
char *t1 = "2000-7-12 17:34:29";
int i;
- ECPGdebug(1, stderr);
- /* exec sql whenever sqlerror do sqlprint ( ) ; */
+ ECPGdebug(1, stderr);
+ /* exec sql whenever sqlerror do sqlprint ( ) ; */
#line 27 "dt_test.pgc"
- { ECPGconnect(__LINE__, 0, "regress1" , NULL, NULL , NULL, 0);
+ { ECPGconnect(__LINE__, 0, "regress1" , NULL, NULL , NULL, 0);
#line 28 "dt_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );}
#line 28 "dt_test.pgc"
- { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "create table date_test ( d date , ts timestamp )", ECPGt_EOIT, ECPGt_EORT);
+ { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "create table date_test ( d date , ts timestamp )", ECPGt_EOIT, ECPGt_EORT);
#line 29 "dt_test.pgc"
if (sqlca.sqlcode < 0) sqlprint ( );}
@@ -84,8 +84,8 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
#line 31 "dt_test.pgc"
- date1 = PGTYPESdate_from_asc(d1, NULL);
- ts1 = PGTYPEStimestamp_from_asc(t1, NULL);
+ date1 = PGTYPESdate_from_asc(d1, NULL);
+ ts1 = PGTYPEStimestamp_from_asc(t1, NULL);
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into date_test ( d , ts ) values ( $1 , $2 )",
ECPGt_date,&(date1),(long)1,(long)1,sizeof(date),
diff --git a/src/interfaces/ecpg/test/expected/preproc-array_of_struct.c b/src/interfaces/ecpg/test/expected/preproc-array_of_struct.c
index 91c8ad55fe8..c60bf51d931 100644
--- a/src/interfaces/ecpg/test/expected/preproc-array_of_struct.c
+++ b/src/interfaces/ecpg/test/expected/preproc-array_of_struct.c
@@ -120,7 +120,7 @@ int main()
ECPGdebug(1, stderr);
-
+
{ ECPGconnect(__LINE__, 0, "regress1" , NULL, NULL , NULL, 0);
#line 50 "array_of_struct.pgc"
diff --git a/src/interfaces/ecpg/test/expected/preproc-cursor.c b/src/interfaces/ecpg/test/expected/preproc-cursor.c
index e755c574613..794e7e26437 100644
--- a/src/interfaces/ecpg/test/expected/preproc-cursor.c
+++ b/src/interfaces/ecpg/test/expected/preproc-cursor.c
@@ -754,7 +754,7 @@ if (sqlca.sqlcode < 0) exit (1);}
#line 239 "cursor.pgc"
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
{ ECPGdisconnect(__LINE__, "CURRENT");
#line 242 "cursor.pgc"
diff --git a/src/interfaces/ecpg/test/expected/preproc-init.c b/src/interfaces/ecpg/test/expected/preproc-init.c
index 1307915fad0..49f2d5d57a6 100644
--- a/src/interfaces/ecpg/test/expected/preproc-init.c
+++ b/src/interfaces/ecpg/test/expected/preproc-init.c
@@ -146,7 +146,7 @@ int main(void)
-
+
/* = 1L */
#line 60 "init.pgc"
@@ -250,7 +250,7 @@ if (sqlca.sqlcode < 0) fe ( ENUM0 );}
/* exec sql whenever sqlerror do sqlnotice ( NULL , 0 ) ; */
#line 97 "init.pgc"
-
+
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "select now ( )", ECPGt_EOIT, ECPGt_EORT);
#line 98 "init.pgc"
diff --git a/src/interfaces/ecpg/test/expected/preproc-outofscope.c b/src/interfaces/ecpg/test/expected/preproc-outofscope.c
index ada4f89d6c3..a30b7215ae4 100644
--- a/src/interfaces/ecpg/test/expected/preproc-outofscope.c
+++ b/src/interfaces/ecpg/test/expected/preproc-outofscope.c
@@ -363,7 +363,7 @@ if (sqlca.sqlcode < 0) exit (1);}
#line 118 "outofscope.pgc"
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
{ ECPGdisconnect(__LINE__, "CURRENT");
#line 121 "outofscope.pgc"
diff --git a/src/interfaces/ecpg/test/expected/preproc-variable.c b/src/interfaces/ecpg/test/expected/preproc-variable.c
index 9f8b36d8a7b..ca3032faca7 100644
--- a/src/interfaces/ecpg/test/expected/preproc-variable.c
+++ b/src/interfaces/ecpg/test/expected/preproc-variable.c
@@ -264,7 +264,7 @@ if (sqlca.sqlcode < 0) exit (1);}
#line 95 "variable.pgc"
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
{ ECPGdisconnect(__LINE__, "CURRENT");
#line 98 "variable.pgc"
diff --git a/src/interfaces/ecpg/test/expected/preproc-whenever.c b/src/interfaces/ecpg/test/expected/preproc-whenever.c
index 1547a16e99f..03f596a9c21 100644
--- a/src/interfaces/ecpg/test/expected/preproc-whenever.c
+++ b/src/interfaces/ecpg/test/expected/preproc-whenever.c
@@ -243,4 +243,4 @@ if (sqlca.sqlcode < 0) exit (1);}
#line 65 "whenever.pgc"
exit (0);
-}
+}
diff --git a/src/interfaces/ecpg/test/expected/sql-array.c b/src/interfaces/ecpg/test/expected/sql-array.c
index cdd2bea0789..3c879561b37 100644
--- a/src/interfaces/ecpg/test/expected/sql-array.c
+++ b/src/interfaces/ecpg/test/expected/sql-array.c
@@ -148,7 +148,7 @@ if (sqlca.sqlcode < 0) sqlprint();}
#line 29 "array.pgc"
- { ECPGtrans(__LINE__, NULL, "begin work");
+ { ECPGtrans(__LINE__, NULL, "begin work");
#line 31 "array.pgc"
if (sqlca.sqlcode < 0) sqlprint();}
@@ -205,7 +205,7 @@ if (sqlca.sqlcode < 0) sqlprint();}
if (sqlca.sqlcode < 0) sqlprint();}
#line 43 "array.pgc"
-
+
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "select f , text from test where i = 1", ECPGt_EOIT,
ECPGt_double,&(f),(long)1,(long)1,sizeof(double),
diff --git a/src/interfaces/ecpg/test/expected/sql-code100.c b/src/interfaces/ecpg/test/expected/sql-code100.c
index e250690e9c8..051fc386229 100644
--- a/src/interfaces/ecpg/test/expected/sql-code100.c
+++ b/src/interfaces/ecpg/test/expected/sql-code100.c
@@ -104,7 +104,7 @@ int main()
ECPGdebug(1,stderr);
-
+
{ ECPGconnect(__LINE__, 0, "regress1" , NULL, NULL , NULL, 0); }
#line 15 "code100.pgc"
@@ -118,7 +118,7 @@ int main()
#line 22 "code100.pgc"
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
-
+
for (index=0;index<10;++index)
{ { ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "insert into test ( payload , index ) values ( 0 , $1 )",
ECPGt_int,&(index),(long)1,(long)1,sizeof(int),
@@ -131,12 +131,12 @@ int main()
#line 31 "code100.pgc"
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
-
+
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "update test set payload = payload + 1 where index = - 1", ECPGt_EOIT, ECPGt_EORT);}
#line 35 "code100.pgc"
if (sqlca.sqlcode!=100) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
-
+
{ ECPGdo(__LINE__, 0, 1, NULL, 0, ECPGst_normal, "delete from test where index = - 1", ECPGt_EOIT, ECPGt_EORT);}
#line 38 "code100.pgc"
@@ -155,7 +155,7 @@ int main()
#line 46 "code100.pgc"
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
-
+
{ ECPGdisconnect(__LINE__, "CURRENT");}
#line 49 "code100.pgc"
diff --git a/src/interfaces/ecpg/test/expected/sql-describe.c b/src/interfaces/ecpg/test/expected/sql-describe.c
index 7a5ab02debf..fd46a292459 100644
--- a/src/interfaces/ecpg/test/expected/sql-describe.c
+++ b/src/interfaces/ecpg/test/expected/sql-describe.c
@@ -453,7 +453,7 @@ if (sqlca.sqlcode < 0) exit (1);}
#line 193 "describe.pgc"
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
{ ECPGdisconnect(__LINE__, "CURRENT");
#line 196 "describe.pgc"
diff --git a/src/interfaces/ecpg/test/expected/sql-dynalloc.c b/src/interfaces/ecpg/test/expected/sql-dynalloc.c
index 02324803338..ff04922fa78 100644
--- a/src/interfaces/ecpg/test/expected/sql-dynalloc.c
+++ b/src/interfaces/ecpg/test/expected/sql-dynalloc.c
@@ -296,28 +296,28 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
for (i=0;i<sqlca.sqlerrd[2];++i)
{
if (i1[i]) printf("NULL, ");
- else printf("%d, ",d1[i]);
+ else printf("%d, ",d1[i]);
if (i2[i]) printf("NULL, ");
- else printf("%f, ",d2[i]);
+ else printf("%f, ",d2[i]);
if (i3[i]) printf("NULL, ");
- else printf("'%s', ",d3[i]);
+ else printf("'%s', ",d3[i]);
if (i4[i]) printf("NULL, ");
- else printf("'%s', ",d4[i]);
+ else printf("'%s', ",d4[i]);
if (i5[i]) printf("NULL, ");
- else printf("'%s', ",d5[i]);
+ else printf("'%s', ",d5[i]);
if (i6[i]) printf("NULL, ");
- else printf("'%s', ",d6[i]);
+ else printf("'%s', ",d6[i]);
if (i7[i]) printf("NULL, ");
- else printf("'%s', ",d7[i]);
+ else printf("'%s', ",d7[i]);
if (i9[i]) printf("NULL, ");
- else printf("'%s', ",d9[i]);
+ else printf("'%s', ",d9[i]);
printf("\n");
}
diff --git a/src/interfaces/ecpg/test/expected/sql-dynalloc2.c b/src/interfaces/ecpg/test/expected/sql-dynalloc2.c
index b729d94cb04..3f200ff6ea4 100644
--- a/src/interfaces/ecpg/test/expected/sql-dynalloc2.c
+++ b/src/interfaces/ecpg/test/expected/sql-dynalloc2.c
@@ -225,10 +225,10 @@ if (sqlca.sqlcode < 0) sqlprint ( );}
for (i=0;i < sqlca.sqlerrd[2];++i)
{
if (ipointer1[i]) printf("NULL, ");
- else printf("%d, ",ip1[i]);
+ else printf("%d, ",ip1[i]);
if (ipointer2[i]) printf("NULL, ");
- else printf("'%s', ",cp2[i]);
+ else printf("'%s', ",cp2[i]);
printf("\n");
}
ECPGfree_auto_mem();
diff --git a/src/interfaces/ecpg/test/expected/sql-fetch.c b/src/interfaces/ecpg/test/expected/sql-fetch.c
index 64b857976ec..908c0dc6888 100644
--- a/src/interfaces/ecpg/test/expected/sql-fetch.c
+++ b/src/interfaces/ecpg/test/expected/sql-fetch.c
@@ -25,7 +25,7 @@
int main() {
/* exec sql begin declare section */
-
+
#line 9 "fetch.pgc"
char str [ 25 ] ;
diff --git a/src/interfaces/ecpg/test/expected/sql-sqlda.c b/src/interfaces/ecpg/test/expected/sql-sqlda.c
index c177ad3f803..e0c35b2ebc0 100644
--- a/src/interfaces/ecpg/test/expected/sql-sqlda.c
+++ b/src/interfaces/ecpg/test/expected/sql-sqlda.c
@@ -278,7 +278,7 @@ if (sqlca.sqlcode == ECPG_NOT_FOUND) break;
if (sqlca.sqlcode < 0) exit (1);}
#line 111 "sqlda.pgc"
-
+
printf("FETCH RECORD %d\n", ++rec);
dump_sqlda(outp_sqlda);
diff --git a/src/interfaces/ecpg/test/pgtypeslib/dt_test.pgc b/src/interfaces/ecpg/test/pgtypeslib/dt_test.pgc
index fa58d2d3542..d56ca87e219 100644
--- a/src/interfaces/ecpg/test/pgtypeslib/dt_test.pgc
+++ b/src/interfaces/ecpg/test/pgtypeslib/dt_test.pgc
@@ -23,15 +23,15 @@ main(void)
char *t1 = "2000-7-12 17:34:29";
int i;
- ECPGdebug(1, stderr);
- exec sql whenever sqlerror do sqlprint();
- exec sql connect to REGRESSDB1;
- exec sql create table date_test (d date, ts timestamp);
+ ECPGdebug(1, stderr);
+ exec sql whenever sqlerror do sqlprint();
+ exec sql connect to REGRESSDB1;
+ exec sql create table date_test (d date, ts timestamp);
exec sql set datestyle to iso;
exec sql set intervalstyle to postgres_verbose;
- date1 = PGTYPESdate_from_asc(d1, NULL);
- ts1 = PGTYPEStimestamp_from_asc(t1, NULL);
+ date1 = PGTYPESdate_from_asc(d1, NULL);
+ ts1 = PGTYPEStimestamp_from_asc(t1, NULL);
exec sql insert into date_test(d, ts) values (:date1, :ts1);
diff --git a/src/interfaces/ecpg/test/preproc/array_of_struct.pgc b/src/interfaces/ecpg/test/preproc/array_of_struct.pgc
index 40d566b4be8..f9e1946b3f1 100644
--- a/src/interfaces/ecpg/test/preproc/array_of_struct.pgc
+++ b/src/interfaces/ecpg/test/preproc/array_of_struct.pgc
@@ -46,7 +46,7 @@ int main()
EXEC SQL end declare section;
ECPGdebug(1, stderr);
-
+
EXEC SQL connect to REGRESSDB1;
EXEC SQL create table customers (c varchar(50), p int);
diff --git a/src/interfaces/ecpg/test/preproc/cursor.pgc b/src/interfaces/ecpg/test/preproc/cursor.pgc
index 397806cb985..a88041a2b85 100644
--- a/src/interfaces/ecpg/test/preproc/cursor.pgc
+++ b/src/interfaces/ecpg/test/preproc/cursor.pgc
@@ -238,7 +238,7 @@ exec sql end declare section;
strcpy(msg, "commit");
exec sql commit;
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
exec sql disconnect;
return (0);
diff --git a/src/interfaces/ecpg/test/preproc/init.pgc b/src/interfaces/ecpg/test/preproc/init.pgc
index 8521e44ee10..11dc01ade45 100644
--- a/src/interfaces/ecpg/test/preproc/init.pgc
+++ b/src/interfaces/ecpg/test/preproc/init.pgc
@@ -67,7 +67,7 @@ int main(void)
int e=y->member;
int c=10>>2;
- bool h=2||1;
+ bool h=2||1;
long iay /* = 1L */ ;
exec sql end declare section;
@@ -94,7 +94,7 @@ int main(void)
exec sql select now();
exec sql whenever sqlerror do fe(ENUM0);
exec sql select now();
- exec sql whenever sqlerror do sqlnotice(NULL, NONO);
+ exec sql whenever sqlerror do sqlnotice(NULL, NONO);
exec sql select now();
return 0;
}
diff --git a/src/interfaces/ecpg/test/preproc/outofscope.pgc b/src/interfaces/ecpg/test/preproc/outofscope.pgc
index 12cd79ac77a..25efe75cca5 100644
--- a/src/interfaces/ecpg/test/preproc/outofscope.pgc
+++ b/src/interfaces/ecpg/test/preproc/outofscope.pgc
@@ -117,7 +117,7 @@ main (void)
strcpy(msg, "commit");
exec sql commit;
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
exec sql disconnect;
return (0);
diff --git a/src/interfaces/ecpg/test/preproc/variable.pgc b/src/interfaces/ecpg/test/preproc/variable.pgc
index 71efa0ddaf1..05420afdb2c 100644
--- a/src/interfaces/ecpg/test/preproc/variable.pgc
+++ b/src/interfaces/ecpg/test/preproc/variable.pgc
@@ -94,7 +94,7 @@ exec sql end declare section;
strcpy(msg, "commit");
exec sql commit;
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
exec sql disconnect;
return (0);
diff --git a/src/interfaces/ecpg/test/preproc/whenever.pgc b/src/interfaces/ecpg/test/preproc/whenever.pgc
index bba78ee0233..9b3ae9e9ec6 100644
--- a/src/interfaces/ecpg/test/preproc/whenever.pgc
+++ b/src/interfaces/ecpg/test/preproc/whenever.pgc
@@ -64,4 +64,4 @@ int main(void)
exec sql select 1 into :i;
exec sql rollback;
exit (0);
-}
+}
diff --git a/src/interfaces/ecpg/test/sql/Makefile b/src/interfaces/ecpg/test/sql/Makefile
index 59e4dd6fc92..18c37b665e1 100644
--- a/src/interfaces/ecpg/test/sql/Makefile
+++ b/src/interfaces/ecpg/test/sql/Makefile
@@ -22,7 +22,7 @@ TESTS = array array.c \
parser parser.c \
quote quote.c \
show show.c \
- insupd insupd.c
+ insupd insupd.c
all: $(TESTS)
diff --git a/src/interfaces/ecpg/test/sql/array.pgc b/src/interfaces/ecpg/test/sql/array.pgc
index d74a1354e5f..fbc67416654 100644
--- a/src/interfaces/ecpg/test/sql/array.pgc
+++ b/src/interfaces/ecpg/test/sql/array.pgc
@@ -28,7 +28,7 @@ EXEC SQL END DECLARE SECTION;
EXEC SQL SET AUTOCOMMIT = ON;
- EXEC SQL BEGIN WORK;
+ EXEC SQL BEGIN WORK;
EXEC SQL CREATE TABLE test (f float, i int, a int[10], text char(10));
@@ -40,7 +40,7 @@ EXEC SQL END DECLARE SECTION;
EXEC SQL COMMIT;
- EXEC SQL BEGIN WORK;
+ EXEC SQL BEGIN WORK;
EXEC SQL SELECT f,text
INTO :f,:text
diff --git a/src/interfaces/ecpg/test/sql/code100.pgc b/src/interfaces/ecpg/test/sql/code100.pgc
index 2ae6d15eade..d9a5e52444a 100644
--- a/src/interfaces/ecpg/test/sql/code100.pgc
+++ b/src/interfaces/ecpg/test/sql/code100.pgc
@@ -11,7 +11,7 @@ int main()
ECPGdebug(1,stderr);
-
+
exec sql connect to REGRESSDB1;
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
@@ -21,7 +21,7 @@ int main()
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql commit work;
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
-
+
for (index=0;index<10;++index)
{ exec sql insert into test
(payload, index)
@@ -30,11 +30,11 @@ int main()
}
exec sql commit work;
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
-
+
exec sql update test
- set payload=payload+1 where index=-1;
+ set payload=payload+1 where index=-1;
if (sqlca.sqlcode!=100) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
-
+
exec sql delete from test where index=-1;
if (sqlca.sqlcode!=100) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
@@ -45,7 +45,7 @@ int main()
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
exec sql commit work;
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
-
+
exec sql disconnect;
if (sqlca.sqlcode) printf("%ld:%s\n",sqlca.sqlcode,sqlca.sqlerrm.sqlerrmc);
return 0;
diff --git a/src/interfaces/ecpg/test/sql/describe.pgc b/src/interfaces/ecpg/test/sql/describe.pgc
index 80361cbe433..cd52c8220be 100644
--- a/src/interfaces/ecpg/test/sql/describe.pgc
+++ b/src/interfaces/ecpg/test/sql/describe.pgc
@@ -192,7 +192,7 @@ exec sql end declare section;
strcpy(msg, "commit");
exec sql commit;
- strcpy(msg, "disconnect");
+ strcpy(msg, "disconnect");
exec sql disconnect;
return (0);
diff --git a/src/interfaces/ecpg/test/sql/dynalloc.pgc b/src/interfaces/ecpg/test/sql/dynalloc.pgc
index 90da1c060a2..8aa810f6c93 100644
--- a/src/interfaces/ecpg/test/sql/dynalloc.pgc
+++ b/src/interfaces/ecpg/test/sql/dynalloc.pgc
@@ -55,28 +55,28 @@ int main(void)
for (i=0;i<sqlca.sqlerrd[2];++i)
{
if (i1[i]) printf("NULL, ");
- else printf("%d, ",d1[i]);
+ else printf("%d, ",d1[i]);
if (i2[i]) printf("NULL, ");
- else printf("%f, ",d2[i]);
+ else printf("%f, ",d2[i]);
if (i3[i]) printf("NULL, ");
- else printf("'%s', ",d3[i]);
+ else printf("'%s', ",d3[i]);
if (i4[i]) printf("NULL, ");
- else printf("'%s', ",d4[i]);
+ else printf("'%s', ",d4[i]);
if (i5[i]) printf("NULL, ");
- else printf("'%s', ",d5[i]);
+ else printf("'%s', ",d5[i]);
if (i6[i]) printf("NULL, ");
- else printf("'%s', ",d6[i]);
+ else printf("'%s', ",d6[i]);
if (i7[i]) printf("NULL, ");
- else printf("'%s', ",d7[i]);
+ else printf("'%s', ",d7[i]);
if (i9[i]) printf("NULL, ");
- else printf("'%s', ",d9[i]);
+ else printf("'%s', ",d9[i]);
printf("\n");
}
diff --git a/src/interfaces/ecpg/test/sql/dynalloc2.pgc b/src/interfaces/ecpg/test/sql/dynalloc2.pgc
index 4a80157a9fc..67d907723a9 100644
--- a/src/interfaces/ecpg/test/sql/dynalloc2.pgc
+++ b/src/interfaces/ecpg/test/sql/dynalloc2.pgc
@@ -39,10 +39,10 @@ int main(void)
for (i=0;i < sqlca.sqlerrd[2];++i)
{
if (ipointer1[i]) printf("NULL, ");
- else printf("%d, ",ip1[i]);
+ else printf("%d, ",ip1[i]);
if (ipointer2[i]) printf("NULL, ");
- else printf("'%s', ",cp2[i]);
+ else printf("'%s', ",cp2[i]);
printf("\n");
}
ECPGfree_auto_mem();
diff --git a/src/interfaces/ecpg/test/sql/fetch.pgc b/src/interfaces/ecpg/test/sql/fetch.pgc
index c25791aa379..83ed46786da 100644
--- a/src/interfaces/ecpg/test/sql/fetch.pgc
+++ b/src/interfaces/ecpg/test/sql/fetch.pgc
@@ -7,7 +7,7 @@ EXEC SQL INCLUDE ../regression;
int main() {
EXEC SQL BEGIN DECLARE SECTION;
char str[25];
- int i, count=1;
+ int i, count=1;
EXEC SQL END DECLARE SECTION;
ECPGdebug(1, stderr);
diff --git a/src/interfaces/ecpg/test/sql/sqlda.pgc b/src/interfaces/ecpg/test/sql/sqlda.pgc
index f49f05f48dd..29774b59090 100644
--- a/src/interfaces/ecpg/test/sql/sqlda.pgc
+++ b/src/interfaces/ecpg/test/sql/sqlda.pgc
@@ -108,7 +108,7 @@ exec sql end declare section;
while (1)
{
strcpy(msg, "fetch");
- exec sql fetch 1 from mycur1 into descriptor outp_sqlda;
+ exec sql fetch 1 from mycur1 into descriptor outp_sqlda;
printf("FETCH RECORD %d\n", ++rec);
dump_sqlda(outp_sqlda);