Revert "Call SetDllDirectory("") after sqlite3 init on cygwin"

This reverts commit 596b0e0a04.

cygwin dropped the patch that necessitated this hack with 3.34, which is
still the current version of sqlite in cygwin. that was in 2020, i.e. we
absolutely should not have to keep this around (especially since it will
silently corrupt the library search path of things linking to libstore!)

Change-Id: I251508b36f26c30533996e8d286aa8e5373eff31
This commit is contained in:
eldritch horrors
2025-01-19 16:40:26 +01:00
parent 98d9fd0584
commit 6870fa89e8
-14
View File
@@ -38,10 +38,6 @@
#include <sys/xattr.h>
#endif
#ifdef __CYGWIN__
#include <windows.h>
#endif
#include <sqlite3.h>
@@ -510,16 +506,6 @@ void LocalStore::openDB(State & state, bool create)
: SQLiteOpenMode::NoCreate;
state.db = SQLite(dbPath, openMode);
#ifdef __CYGWIN__
/* The cygwin version of sqlite3 has a patch which calls
SetDllDirectory("/usr/bin") on init. It was intended to fix extension
loading, which we don't use, and the effect of SetDllDirectory is
inherited by child processes, and causes libraries to be loaded from
/usr/bin instead of $PATH. This breaks quite a few things (e.g.
checkPhase on openssh), so we set it back to default behaviour. */
SetDllDirectoryW(L"");
#endif
/* !!! check whether sqlite has been built with foreign key
support */