From 4f5add9f6eba1385e1b685c4a8e0ba07388ebe15 Mon Sep 17 00:00:00 2001 From: Andrea Zagli Date: Tue, 15 Dec 2015 11:46:01 +0100 Subject: [PATCH] Error only when sql insert and update executions return not 1. --- src/form.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/form.c b/src/form.c index 53d93bf..2b5ea3a 100644 --- a/src/form.c +++ b/src/form.c @@ -391,7 +391,7 @@ zak_form_gdaex_provider_insert (ZakFormIProvider *provider, GPtrArray *elements) } - if (gdaex_sql_builder_execute (sqlb, priv->gdaex, NULL) <= 0) + if (gdaex_sql_builder_execute (sqlb, priv->gdaex, NULL) != 1) { ret = FALSE; } @@ -456,7 +456,7 @@ zak_form_gdaex_provider_update (ZakFormIProvider *provider, GPtrArray *elements) } } - if (gdaex_sql_builder_execute (sqlb, priv->gdaex, NULL) <= 0) + if (gdaex_sql_builder_execute (sqlb, priv->gdaex, NULL) != 1) { ret = FALSE; } -- 2.49.0