From 19d97ac8211fdcbb9ed97dcd0a19317fcb8165f8 Mon Sep 17 00:00:00 2001 From: brodsom Date: Thu, 27 Mar 2003 17:15:48 +0000 Subject: [PATCH] Fix some wrong format strings/argument lists --- src/gpre/ada.cpp | 8 +++----- src/gpre/c_cxx.cpp | 14 +++++--------- src/gpre/cob.cpp | 12 +++++------- src/gpre/ftn.cpp | 8 +++----- src/gpre/int.cpp | 8 ++++---- src/gpre/int_cxx.cpp | 8 ++++---- 6 files changed, 24 insertions(+), 34 deletions(-) diff --git a/src/gpre/ada.cpp b/src/gpre/ada.cpp index e1f0502851..847ac0c993 100644 --- a/src/gpre/ada.cpp +++ b/src/gpre/ada.cpp @@ -24,7 +24,7 @@ // //____________________________________________________________ // -// $Id: ada.cpp,v 1.14 2003-02-27 16:05:18 brodsom Exp $ +// $Id: ada.cpp,v 1.15 2003-03-27 17:15:48 brodsom Exp $ // #include "firebird.h" @@ -2367,8 +2367,7 @@ static void gen_function( ACT function, int column) request = action->act_request; - ib_fprintf(out_file, "static %s_r (request, transaction", - request->req_handle, request->req_handle, request->req_trans); + ib_fprintf(out_file, "static %s_r (request, transaction", request->req_handle); if (port = request->req_vport) for (reference = port->por_references; reference; @@ -2376,8 +2375,7 @@ static void gen_function( ACT function, int column) ib_fprintf(out_file, ", %s", gen_name(s, reference->ref_source, TRUE)); ib_fprintf(out_file, - ")\n isc_req_handle\trequest;\n isc_tr_handle\ttransaction;\n", - request->req_handle, request->req_trans); + ")\n isc_req_handle\trequest;\n isc_tr_handle\ttransaction;\n"); if (port) for (reference = port->por_references; reference; diff --git a/src/gpre/c_cxx.cpp b/src/gpre/c_cxx.cpp index f25f0a9cf8..36c74baf8e 100644 --- a/src/gpre/c_cxx.cpp +++ b/src/gpre/c_cxx.cpp @@ -27,7 +27,7 @@ // //____________________________________________________________ // -// $Id: c_cxx.cpp,v 1.18 2003-02-28 13:19:34 brodsom Exp $ +// $Id: c_cxx.cpp,v 1.19 2003-03-27 17:15:46 brodsom Exp $ // #include "firebird.h" @@ -2603,9 +2603,7 @@ static void gen_function( ACT function, int column) request = action->act_request; -#pragma FB_COMPILER_MESSAGE("fix format string") - ib_fprintf(out_file, "static %s_r (request, transaction ", - request->req_handle, request->req_handle, request->req_trans); + ib_fprintf(out_file, "static %s_r (request, transaction ", request->req_handle); if (port = request->req_vport) for (reference = port->por_references; reference; @@ -2613,10 +2611,8 @@ static void gen_function( ACT function, int column) ib_fprintf(out_file, ", %s", gen_name(s, reference->ref_source, TRUE)); -#pragma FB_COMPILER_MESSAGE("fix format string") ib_fprintf(out_file, - ")\n isc_req_handle\trequest;\n isc_tr_handle\ttransaction;\n", - request->req_handle, request->req_trans); + ")\n isc_req_handle\trequest;\n isc_tr_handle\ttransaction;\n"); if (port) for (reference = port->por_references; reference; @@ -3526,7 +3522,7 @@ static void gen_request( GPRE_REQ request) (request->req_flags & REQ_extend_dpb) ? "" : CONST_STR, request->req_ident, request->req_length); printa(0, "static %schar\n isc_%d [] = {", - CONST_STR, request->req_ident, request->req_length); + CONST_STR, request->req_ident); string_type = "blr"; if (sw_raw) { gen_raw(request->req_blr, request->req_length); @@ -3609,7 +3605,7 @@ static void gen_request( GPRE_REQ request) IBERROR("internal error during BLR generation"); } printa(INDENT, "};\t/* end of %s string for request isc_%d */\n", - string_type, request->req_ident, request->req_length); + string_type, request->req_ident); } // Print out slice description language if there are arrays associated with request diff --git a/src/gpre/cob.cpp b/src/gpre/cob.cpp index b024a2cc00..180bd13ff1 100644 --- a/src/gpre/cob.cpp +++ b/src/gpre/cob.cpp @@ -27,7 +27,7 @@ // //____________________________________________________________ // -// $Id: cob.cpp,v 1.20 2003-03-02 17:47:20 fsg Exp $ +// $Id: cob.cpp,v 1.21 2003-03-27 17:15:46 brodsom Exp $ // // 2002.10.27 Sean Leyne - Completed removal of obsolete "DG_X86" port // 2002.10.27 Sean Leyne - Code Cleanup, removed obsolete "UNIXWARE" port @@ -3010,8 +3010,7 @@ static void gen_function( ACT function) request = action->act_request; - ib_fprintf(out_file, "static %s_r (request, transaction", - request->req_handle, request->req_handle, request->req_trans); + ib_fprintf(out_file, "static %s_r (request, transaction", request->req_handle); if (port = request->req_vport) for (reference = port->por_references; reference; @@ -3020,8 +3019,7 @@ static void gen_function( ACT function) gen_name(s, reference->ref_source, TRUE)); ib_fprintf(out_file, - ")\n isc_req_handle\trequest;\n isc_tr_handle\ttransaction;\n", - request->req_handle, request->req_trans); + ")\n isc_req_handle\trequest;\n isc_tr_handle\ttransaction;\n"); if (port) for (reference = port->por_references; reference; @@ -4846,7 +4844,7 @@ static void make_array_declaration( REF reference) for (dimension = field->fld_array_info->ary_dimension, i = 3; dimension->dim_next; dimension = dimension->dim_next, i += 2) { dimension_size = dimension->dim_upper - dimension->dim_lower + 1; - printa(space, FALSE, "%02.d %s%d%s%d OCCURS %d TIMES.", + printa(space, FALSE, "%02d %s%d%s%d OCCURS %d TIMES.", i, names[ISC_], field->fld_array_info->ary_ident, @@ -4856,7 +4854,7 @@ static void make_array_declaration( REF reference) p = string1; dimension_size = dimension->dim_upper - dimension->dim_lower + 1; - sprintf(p, "%02.d %s%d OCCURS %d TIMES ", + sprintf(p, "%02d %s%d OCCURS %d TIMES ", i, names[ISC_], field->fld_array_info->ary_ident, dimension_size); while (*p) p++; diff --git a/src/gpre/ftn.cpp b/src/gpre/ftn.cpp index f3f22067dd..04d8e9fced 100644 --- a/src/gpre/ftn.cpp +++ b/src/gpre/ftn.cpp @@ -24,7 +24,7 @@ // //____________________________________________________________ // -// $Id: ftn.cpp,v 1.18 2003-03-02 17:47:20 fsg Exp $ +// $Id: ftn.cpp,v 1.19 2003-03-27 17:15:45 brodsom Exp $ // // 2002.10.28 Sean Leyne - Completed removal of obsolete "DGUX" port // 2002.10.28 Sean Leyne - Completed removal of obsolete "SGI" port @@ -5080,8 +5080,7 @@ static void gen_function( ACT function) request = action->act_request; - ib_fprintf(out_file, "static %s_r (request, transaction", - request->req_handle, request->req_handle, request->req_trans); + ib_fprintf(out_file, "static %s_r (request, transaction", request->req_handle); if (port = request->req_vport) for (reference = port->por_references; reference; @@ -5090,8 +5089,7 @@ static void gen_function( ACT function) gen_name(s, reference->ref_source, TRUE)); ib_fprintf(out_file, - ")\n isc_req_handle\trequest;\n isc_tr_handle\ttransaction;\n", - request->req_handle, request->req_trans); + ")\n isc_req_handle\trequest;\n isc_tr_handle\ttransaction;\n"); if (port) for (reference = port->por_references; reference; diff --git a/src/gpre/int.cpp b/src/gpre/int.cpp index e27835a305..a35f93f65c 100644 --- a/src/gpre/int.cpp +++ b/src/gpre/int.cpp @@ -25,7 +25,7 @@ // //____________________________________________________________ // -// $Id: int.cpp,v 1.11 2003-03-03 08:36:03 brodsom Exp $ +// $Id: int.cpp,v 1.12 2003-03-27 17:15:44 brodsom Exp $ // #include "firebird.h" @@ -201,11 +201,11 @@ static void asgn_from( REF reference, int column) if (!field || field->fld_dtype == dtype_text) ib_fprintf(out_file, VTO_CALL, JRD_VTOF, - value, variable, field->fld_length, sw_interp); + value, variable, field->fld_length); else if (!field || field->fld_dtype == dtype_cstring) ib_fprintf(out_file, VTO_CALL, GDS_VTOV, - value, variable, field->fld_length, sw_interp); + value, variable, field->fld_length); else ib_fprintf(out_file, "%s = %s;", variable, value); } @@ -507,7 +507,7 @@ static void gen_request( GPRE_REQ request) ib_fprintf(out_file, "static const UCHAR\tjrd_%d [%d] =", request->req_ident, request->req_length); align(INDENT); - ib_fprintf(out_file, "{\t/* blr string */\n", request->req_ident); + ib_fprintf(out_file, "{\t/* blr string */\n"); if (sw_raw) gen_raw(request); diff --git a/src/gpre/int_cxx.cpp b/src/gpre/int_cxx.cpp index 5add6103fe..7edaba6d05 100644 --- a/src/gpre/int_cxx.cpp +++ b/src/gpre/int_cxx.cpp @@ -25,7 +25,7 @@ // //____________________________________________________________ // -// $Id: int_cxx.cpp,v 1.9 2003-03-03 08:36:03 brodsom Exp $ +// $Id: int_cxx.cpp,v 1.10 2003-03-27 17:15:43 brodsom Exp $ // #include "firebird.h" @@ -204,11 +204,11 @@ static void asgn_from( REF reference, int column) if (!field || field->fld_dtype == dtype_text) ib_fprintf(out_file, VTO_CALL, JRD_VTOF, - value, variable, field->fld_length, sw_interp); + value, variable, field->fld_length); else if (!field || field->fld_dtype == dtype_cstring) ib_fprintf(out_file, VTO_CALL, GDS_VTOV, - value, variable, field->fld_length, sw_interp); + value, variable, field->fld_length); else ib_fprintf(out_file, "%s = %s;", variable, value); } @@ -513,7 +513,7 @@ static void gen_request( GPRE_REQ request) ib_fprintf(out_file, "static const UCHAR\tjrd_%d [%d] =", request->req_ident, request->req_length); align(INDENT); - ib_fprintf(out_file, "{\t/* blr string */\n", request->req_ident); + ib_fprintf(out_file, "{\t/* blr string */\n"); if (sw_raw) gen_raw(request);