Skip to content

Commit

Permalink
check if SQLITE_OPEN_NOFOLLOW is defined
Browse files Browse the repository at this point in the history
under MacOS 11 BigSur(macos-latest) the macro SQLITE_OPEN_NOFOLLOW
is not defined so it may cause compilation issues for those versions
  • Loading branch information
UnixY2K committed Dec 14, 2022
1 parent 403839d commit d4ff61f
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Database.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ const int OPEN_NOMUTEX = SQLITE_OPEN_NOMUTEX;
const int OPEN_FULLMUTEX = SQLITE_OPEN_FULLMUTEX;
const int OPEN_SHAREDCACHE = SQLITE_OPEN_SHAREDCACHE;
const int OPEN_PRIVATECACHE = SQLITE_OPEN_PRIVATECACHE;
#if SQLITE_VERSION_NUMBER >= 3031000
// check if sqlite version is >= 3.31.0 and SQLITE_OPEN_NOFOLLOW is defined
#if SQLITE_VERSION_NUMBER >= 3031000 && defined(SQLITE_OPEN_NOFOLLOW)
const int OPEN_NOFOLLOW = SQLITE_OPEN_NOFOLLOW;
#else
const int OPEN_NOFOLLOW = 0;
Expand Down

0 comments on commit d4ff61f

Please sign in to comment.