mirror of
https://github.com/zeek/zeek.git
synced 2025-10-09 18:18:19 +00:00
Merge remote-tracking branch 'origin/topic/vern/dup-rec-fields2'
* origin/topic/vern/dup-rec-fields2: fix for crashes when record definitions repeat a field name Removed dead if !init code during merge.
This commit is contained in:
commit
d4a84e7442
5 changed files with 56 additions and 14 deletions
|
@ -1,3 +1,7 @@
|
|||
### BTest baseline data generated by btest-diff. Do not edit. Use "btest -U/-u" to update. Requires BTest >= 0.63.
|
||||
error in <...>/record-duplicate-fields.zeek, line 7: Duplicate field 'a' found in record definition
|
||||
|
||||
error in <...>/record-duplicate-fields.zeek, line 7: duplicate field 'a' found in record definition
|
||||
error in <...>/record-duplicate-fields.zeek, line 17: duplicate field 'a' found in record definition
|
||||
error in <...>/record-duplicate-fields.zeek, line 23: duplicate field 'a' found in record definition
|
||||
error in <...>/record-duplicate-fields.zeek, line 32: duplicate field 'a' found in record definition
|
||||
error in <...>/record-duplicate-fields.zeek, line 32: duplicate field 'b' found in record definition
|
||||
error in <...>/record-duplicate-fields.zeek, line 32: duplicate field 'a' found in record definition
|
||||
|
|
|
@ -6,8 +6,39 @@ type test: record {
|
|||
a: string &optional;
|
||||
};
|
||||
|
||||
type r1: record {
|
||||
a: count;
|
||||
b: count;
|
||||
};
|
||||
|
||||
type r2: record {
|
||||
a: count;
|
||||
a: count;
|
||||
};
|
||||
|
||||
type r3: record {
|
||||
b: count;
|
||||
a: count;
|
||||
a: count;
|
||||
};
|
||||
|
||||
type r4: record {
|
||||
a: count;
|
||||
b: count;
|
||||
a: count;
|
||||
b: count;
|
||||
a: count;
|
||||
c: count;
|
||||
};
|
||||
|
||||
global x1: r1;
|
||||
global x2: r2;
|
||||
global x3: r3;
|
||||
global x4: r4;
|
||||
|
||||
event zeek_init()
|
||||
{
|
||||
local a = test($a=5);
|
||||
print a;
|
||||
print x1, x2, x3, x4;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue