Skip to content

Commit b0ababd

Browse files
committed
Set h_exec_query_sqlite as a #define
1 parent 41babac commit b0ababd

File tree

2 files changed

+1
-19
lines changed

2 files changed

+1
-19
lines changed

include/hoel.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -531,7 +531,7 @@ long long int h_last_insert_id_sqlite(const struct _h_connection * conn);
531531
* @param query the SQL query to execute
532532
* @return H_OK on success
533533
*/
534-
int h_exec_query_sqlite(const struct _h_connection * conn, const char * query);
534+
#define h_exec_query_sqlite(conn, query) h_execute_query_sqlite(conn, query)
535535

536536
/**
537537
* h_execute_query_sqlite

src/hoel-sqlite.c

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -211,17 +211,6 @@ int h_select_query_sqlite(const struct _h_connection * conn, const char * query,
211211
}
212212
}
213213

214-
/**
215-
* h_exec_query_sqlite
216-
* Execute a query on a sqlite connection
217-
* Should not be executed by the user because all parameters are supposed to be correct
218-
* No result is returned, useful for single INSERT, UPDATE or DELETE statements
219-
* return H_OK on success
220-
*/
221-
int h_exec_query_sqlite(const struct _h_connection * conn, const char * query) {
222-
return h_execute_query_sqlite(conn, query);
223-
}
224-
225214
/**
226215
* h_execute_query_sqlite
227216
* Execute a query on a sqlite connection
@@ -351,13 +340,6 @@ long long int h_last_insert_id_sqlite(const struct _h_connection * conn) {
351340
return 0;
352341
}
353342

354-
int h_exec_query_sqlite(const struct _h_connection * conn, const char * query) {
355-
UNUSED(conn);
356-
UNUSED(query);
357-
y_log_message(Y_LOG_LEVEL_ERROR, "Hoel was not compiled with SQLite backend");
358-
return H_ERROR;
359-
}
360-
361343
int h_execute_query_sqlite(const struct _h_connection * conn, const char * query) {
362344
UNUSED(conn);
363345
UNUSED(query);

0 commit comments

Comments
 (0)