config_passthrough.cpp

This commit is contained in:
Antonio SJ Musumeci 2024-04-08 17:43:49 -05:00
parent 1907168452
commit 4d64b8c9ad

View file

@ -31,7 +31,12 @@ template<>
int
Passthrough::from_string(const std::string &s_)
{
_data = PassthroughEnum::_from_string_nothrow(s_);
auto x = PassthroughEnum::_from_string_nothrow(s_);
if(!x)
return -EINVAL;
_data = x;
return 0;
}