diff --git a/FTL.h b/FTL.h index 356a223a..9bcf7cba 100644 --- a/FTL.h +++ b/FTL.h @@ -36,8 +36,6 @@ #include // syslog #include -// SQLite -#include "sqlite3.h" // tolower() #include // Unix socket @@ -174,7 +172,7 @@ typedef struct { int domainID; int clientID; int forwardID; - sqlite3_int64 db; + int64_t db; int id; // the ID is a (signed) int in dnsmasq, so no need for a long int here bool complete; unsigned char privacylevel; diff --git a/api.c b/api.c index 621e73f4..16ee405d 100644 --- a/api.c +++ b/api.c @@ -11,6 +11,8 @@ #include "FTL.h" #include "api.h" #include "version.h" +// needed for sqlite3_libversion() +#include "sqlite3.h" #define min(a,b) ({ __typeof__ (a) _a = (a); __typeof__ (b) _b = (b); _a < _b ? _a : _b; }) diff --git a/database.c b/database.c index d63c4c05..cd20e871 100644 --- a/database.c +++ b/database.c @@ -10,6 +10,7 @@ #include "FTL.h" #include "shmem.h" +#include "sqlite3.h" static sqlite3 *db; bool database = false; diff --git a/networktable.c b/networktable.c index 67f564cb..d6cf0b86 100644 --- a/networktable.c +++ b/networktable.c @@ -10,6 +10,7 @@ #include "FTL.h" #include "shmem.h" +#include "sqlite3.h" #define ARPCACHE "/proc/net/arp" // Private prototypes