Move check for (unsupported) bind_ph/is_inout so it always error-out.
>From 5a94a490b40f8472a04b98fa8f78bcbc3157f8d8 Mon Sep 17 00:00:00 2001 From: "Yuriy M. Kaminskiy" <yum...@gmail.com> Date: Mon, 17 Oct 2011 07:47:50 +0400 Subject: [PATCH 2/2] Move misplaced check for (unsupported) bind/InOut
--- dbdimp.c | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-) diff --git a/dbdimp.c b/dbdimp.c index 1da8034..5b8adef 100644 --- a/dbdimp.c +++ b/dbdimp.c @@ -1197,6 +1197,10 @@ sqlite_bind_ph(SV *sth, imp_sth_t *imp_sth, croak_if_stmt_is_null(); + if (is_inout) { + sqlite_error(sth, -2, "InOut bind params not implemented"); + return FALSE; /* -> &sv_no in SQLite.xsi */ + } if (!looks_like_number(param)) { STRLEN len; char *paramstring; @@ -1215,10 +1219,6 @@ sqlite_bind_ph(SV *sth, imp_sth_t *imp_sth, } } else { - if (is_inout) { - sqlite_error(sth, -2, "InOut bind params not implemented"); - return FALSE; /* -> &sv_no in SQLite.xsi */ - } pos = 2 * (SvIV(param) - 1); } sqlite_trace(sth, imp_sth, 3, form("bind into 0x%p: %"IVdf" => %s (%"IVdf") pos %d", imp_sth->params, SvIV(param), SvPV_nolen_undef_ok(value), sql_type, pos)); -- 1.7.6.4
_______________________________________________ DBD-SQLite mailing list DBD-SQLite@lists.scsys.co.uk http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/dbd-sqlite