mirror of
https://github.com/tristanpenman/valijson.git
synced 2024-12-12 10:13:51 +01:00
Fix memory leak in concrete constraints
This patch fixes a memory leak found from ASAN testing. There may be more here, but this is the only one blocking our workflow.
This commit is contained in:
parent
c1e75c700f
commit
1f964c1299
@ -189,16 +189,16 @@ public:
|
||||
|
||||
adapters::FrozenValue * getValue() const
|
||||
{
|
||||
return m_value;
|
||||
return m_value.get();
|
||||
}
|
||||
|
||||
void setValue(const adapters::Adapter &value)
|
||||
{
|
||||
m_value = value.freeze();
|
||||
m_value = std::unique_ptr<adapters::FrozenValue>(value.freeze());
|
||||
}
|
||||
|
||||
private:
|
||||
adapters::FrozenValue *m_value;
|
||||
std::unique_ptr<adapters::FrozenValue> m_value;
|
||||
};
|
||||
|
||||
/**
|
||||
|
Loading…
Reference in New Issue
Block a user