mirror of
https://github.com/nlohmann/json.git
synced 2026-04-07 00:28:56 +00:00
Add assertion if nullptr is passed to parse function (#3593)
Addresses #3584
This commit is contained in:
@@ -50,7 +50,9 @@ class file_input_adapter
|
||||
JSON_HEDLEY_NON_NULL(2)
|
||||
explicit file_input_adapter(std::FILE* f) noexcept
|
||||
: m_file(f)
|
||||
{}
|
||||
{
|
||||
JSON_ASSERT(m_file != nullptr);
|
||||
}
|
||||
|
||||
// make class move-only
|
||||
file_input_adapter(const file_input_adapter&) = delete;
|
||||
|
||||
Reference in New Issue
Block a user