1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-12 13:01:09 +03:00

Better loadable extension handling in the Win32 VFS when compiled for Cygwin.

FossilOrigin-Name: 6676475c47558a52cb2632e92a541e13d143b2dc
This commit is contained in:
mistachkin
2014-02-21 05:44:18 +00:00
parent 4d87aaed56
commit 5b4627e957
3 changed files with 26 additions and 8 deletions

View File

@@ -5141,8 +5141,23 @@ static int winFullPathname(
*/
static void *winDlOpen(sqlite3_vfs *pVfs, const char *zFilename){
HANDLE h;
#if defined(__CYGWIN__)
int nFull = pVfs->mxPathname+1;
char *zFull = sqlite3MallocZero( nFull );
void *zConverted = 0;
if( zFull==0 ){
return 0;
}
if( winFullPathname(pVfs, zFilename, nFull, zFull)!=SQLITE_OK ){
sqlite3_free(zFull);
return 0;
}
zConverted = winConvertFromUtf8Filename(zFull);
sqlite3_free(zFull);
#else
void *zConverted = winConvertFromUtf8Filename(zFilename);
UNUSED_PARAMETER(pVfs);
#endif
if( zConverted==0 ){
return 0;
}