diff options
author | gramanas <anastasis.gramm2@gmail.com> | 2018-05-08 12:34:11 +0300 |
---|---|---|
committer | gramanas <anastasis.gramm2@gmail.com> | 2018-05-08 12:34:11 +0300 |
commit | 00faacfa1ba2af7dd6dbd441e0ede57029d92686 (patch) | |
tree | 8b9454a14b3a30af34b7aea366ae082088f2cc19 /src/dblayer.c | |
parent | 1f30b63db9aeab2332d269939c46c2fd9a0f0f8d (diff) | |
parent | 6ff122b83a32c7dcab917cbf3f493d93aba20f3d (diff) | |
download | ck-00faacfa1ba2af7dd6dbd441e0ede57029d92686.tar.gz ck-00faacfa1ba2af7dd6dbd441e0ede57029d92686.tar.bz2 ck-00faacfa1ba2af7dd6dbd441e0ede57029d92686.zip |
Merge branch 'master' into dev
Diffstat (limited to 'src/dblayer.c')
-rw-r--r-- | src/dblayer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/dblayer.c b/src/dblayer.c index a18d0d0..8014d08 100644 --- a/src/dblayer.c +++ b/src/dblayer.c @@ -40,7 +40,7 @@ int check_initialized_DB(sqlite3 *db) { dbh_form_query_select_all_tables(sql); sqlite3_stmt *stmt; - int rc = sqlite3_prepare_v2(db, sql, strlen(sql), &stmt, NULL); + sqlite3_prepare_v2(db, sql, strlen(sql), &stmt, NULL); int program_table_ok, config_table_ok, rel_table_ok = 0; while (sqlite3_step(stmt) != SQLITE_DONE) { @@ -306,8 +306,8 @@ int program_has_primary_config(DB *db, const int pid, char *ret, int *sec) { PRINT_ERR("while preparing program_has_primary_exists sql."); return -2; } + sqlite3_bind_int(stmt, 1, pid); - int count = 0; while (sqlite3_step(stmt) == SQLITE_ROW) { if (sqlite3_column_int(stmt, 0) == 1) { if (ret) { |