ShellManager: catch exception thrown by env var functors

This commit is contained in:
Maxime Coste 2013-02-19 19:06:13 +01:00
parent a83731c8e1
commit 02b01e2f0a

View File

@ -110,8 +110,12 @@ String ShellManager::pipe(const String& input,
if (env_var != m_env_vars.end())
{
String value = env_var->second(name, context);
setenv(("kak_" + name).c_str(), value.c_str(), 1);
try
{
String value = env_var->second(name, context);
setenv(("kak_" + name).c_str(), value.c_str(), 1);
}
catch (runtime_error&) {}
}
}