Added missing depth check
This commit is contained in:
parent
81c8d89341
commit
dd9197c9d5
1 changed files with 1 additions and 0 deletions
|
|
@ -640,6 +640,7 @@ namespace fc
|
||||||
template<typename T, typename... Args>
|
template<typename T, typename... Args>
|
||||||
void from_variant( const variant& v, boost::multi_index_container<T,Args...>& c, uint32_t max_depth )
|
void from_variant( const variant& v, boost::multi_index_container<T,Args...>& c, uint32_t max_depth )
|
||||||
{
|
{
|
||||||
|
_FC_ASSERT( max_depth > 0, "Recursion depth exceeded!" );
|
||||||
const variants& vars = v.get_array();
|
const variants& vars = v.get_array();
|
||||||
c.clear();
|
c.clear();
|
||||||
for( const auto& item : vars )
|
for( const auto& item : vars )
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue