Discussion:
[PATCH 2/2] Move misplaced check for (unsupported) bind/InOut
Yuriy M. Kaminskiy
2011-10-17 03:47:50 UTC
Permalink
---
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


--------------090503010403070704050404--
Loading...