diff --git a/avs_core/core/PluginManager.cpp b/avs_core/core/PluginManager.cpp index 33791b5ec..d9c69f6f4 100644 --- a/avs_core/core/PluginManager.cpp +++ b/avs_core/core/PluginManager.cpp @@ -570,7 +570,7 @@ void PluginManager::AddAutoloadDir(const std::string &dirPath, bool toFront) GetModuleFileName(NULL, ExeFilePath, AVS_MAX_PATH); #else // AVS_POSIX std::string ExeFilePath; - char buf[PATH_MAX + 1]; + char buf[PATH_MAX + 1] {}; #ifdef AVS_LINUX if (readlink("/proc/self/exe", buf, sizeof(buf) - 1) != -1) #elif defined(AVS_MACOS) diff --git a/avs_core/core/avisynth.cpp b/avs_core/core/avisynth.cpp index b535fcbdd..4708c3cb6 100644 --- a/avs_core/core/avisynth.cpp +++ b/avs_core/core/avisynth.cpp @@ -2222,7 +2222,9 @@ ScriptEnvironment::ScriptEnvironment() FrontCache(NULL), nTotalThreads(1), nMaxFilterInstances(1), - graphAnalysisEnable(false) + graphAnalysisEnable(false), + LogLevel(LOGLEVEL_NONE), + cacheMode(CACHE_DEFAULT) { #ifdef XP_TLS if(dwTlsIndex == 0) @@ -2257,8 +2259,6 @@ ScriptEnvironment::ScriptEnvironment() } #endif - - auto cpuDevice = Devices->GetCPUDevice(); threadEnv->GetTLS()->currentDevice = cpuDevice; diff --git a/avs_core/core/parser/tokenizer.cpp b/avs_core/core/parser/tokenizer.cpp index 62dc6a322..08fa7fb8d 100644 --- a/avs_core/core/parser/tokenizer.cpp +++ b/avs_core/core/parser/tokenizer.cpp @@ -64,6 +64,7 @@ Tokenizer::Tokenizer(Tokenizer* old) { pc = old->pc; line = old->line; + type = old->type; NextToken(); }