Allow to use operating systems's native dynamic library extension

This commit is contained in:
2018-07-20 22:43:52 +02:00
parent abb91a9874
commit dc4c51ca5a
2 changed files with 2 additions and 2 deletions

View File

@@ -10780,7 +10780,7 @@ static int vm_builtin_import(ph7_context *pCtx, int nArg, ph7_value **apArg) {
SyStringInitFromBuf(&pModule.sName, zStr, nLen);
unsigned char bfile[255] = {0};
unsigned char *file;
snprintf(bfile, sizeof(bfile) - 1, "./%s.lib", zStr);
snprintf(bfile, sizeof(bfile) - 1, "./%s%s", zStr, PH7_LIBRARY_SUFFIX);
file = bfile;
SyStringInitFromBuf(&pModule.sFile, file, nLen);
#ifdef __WINNT__