mirror of
https://github.com/zeek/zeek.git
synced 2025-10-07 17:18:20 +00:00
Make backend options a record, move actual options to be sub-records
This commit is contained in:
parent
64f3969434
commit
a485b1d237
23 changed files with 71 additions and 73 deletions
|
@ -19,7 +19,8 @@ zeek::storage::BackendPtr StorageDummy::Instantiate(std::string_view tag) {
|
|||
* with a corresponding message.
|
||||
*/
|
||||
zeek::storage::ErrorResult StorageDummy::DoOpen(zeek::RecordValPtr options, zeek::storage::OpenResultCallback* cb) {
|
||||
bool open_fail = options->GetField<zeek::BoolVal>("open_fail")->Get();
|
||||
zeek::RecordValPtr backend_options = options->GetField<zeek::RecordVal>("dummy");
|
||||
bool open_fail = backend_options->GetField<zeek::BoolVal>("open_fail")->Get();
|
||||
if ( open_fail )
|
||||
return "open_fail was set to true, returning error";
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue