mirror of
https://github.com/zeek/zeek.git
synced 2025-10-02 06:38:20 +00:00
Merge remote-tracking branch 'origin/topic/vern/CPP-when-capture-naming'
* origin/topic/vern/CPP-when-capture-naming: fixed "-O gen-C++" naming of "when" captures to avoid ambiguities due to inlining Simplified & made more robust maintenance helper script for "-O gen-C++" testing "-a cpp" baseline updates to reflect recent BTest changes
This commit is contained in:
commit
821218e7b2
6 changed files with 25 additions and 13 deletions
13
CHANGES
13
CHANGES
|
@ -1,3 +1,16 @@
|
|||
7.1.0-dev.428 | 2024-10-29 13:50:05 +0100
|
||||
|
||||
* fixed "-O gen-C++" naming of "when" captures to avoid ambiguities due to inlining (Vern Paxson, Corelight)
|
||||
|
||||
Previously there was logic for doing this, but it was ineffectual
|
||||
due to the order in which canonicalization was done. This problem
|
||||
manifested non-deterministically depending on order-of-generation
|
||||
of "when" lambdas, which is why previous testing didn't catch it.
|
||||
|
||||
* Simplified & made more robust maintenance helper script for "-O gen-C++" testing (Vern Paxson, Corelight)
|
||||
|
||||
* "-a cpp" baseline updates to reflect recent BTest changes (Vern Paxson, Corelight)
|
||||
|
||||
7.1.0-dev.423 | 2024-10-24 07:08:45 -0700
|
||||
|
||||
* Telemetry framework: move BIFs to the primary-bif stage (Christian Kreibich, Corelight)
|
||||
|
|
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
|||
7.1.0-dev.423
|
||||
7.1.0-dev.428
|
||||
|
|
|
@ -133,15 +133,13 @@ string CPPCompile::LocalName(const ID* l) const { return Canonicalize(trim_name(
|
|||
|
||||
string CPPCompile::CaptureName(const ID* c) const {
|
||||
// We want to strip both the module and any inlining appendage.
|
||||
auto n = Canonicalize(trim_name(c).c_str());
|
||||
auto tn = trim_name(c);
|
||||
|
||||
auto appendage = n.find(".");
|
||||
if ( appendage != string::npos ) {
|
||||
n.erase(n.begin() + appendage, n.end());
|
||||
n.push_back('_');
|
||||
}
|
||||
auto appendage = tn.find(".");
|
||||
if ( appendage != string::npos )
|
||||
tn.erase(tn.begin() + appendage, tn.end());
|
||||
|
||||
return n;
|
||||
return Canonicalize(tn.c_str());
|
||||
}
|
||||
|
||||
string CPPCompile::Canonicalize(const char* name) const {
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
#! /bin/sh
|
||||
|
||||
find ../testing/btest -type f |
|
||||
grep -E -v 'Baseline|\.tmp|__load__' |
|
||||
grep -E '\.(zeek|test)$' |
|
||||
sort |
|
||||
xargs grep -E -l '@TEST' |
|
||||
xargs grep -E -l '^[ ]*(event|print)' |
|
||||
xargs grep -E -c 'REQUIRES.*CPP.*((!=.*1)|(==.*0))' |
|
||||
grep ':0$' |
|
||||
sed 's,:0,,'
|
||||
sed 's,:0,,' |
|
||||
sort
|
||||
|
|
|
@ -7,7 +7,7 @@
|
|||
#open XXXX-XX-XX-XX-XX-XX
|
||||
#fields ts uid id.orig_h id.orig_p id.resp_h id.resp_p name addl notice peer source
|
||||
#types time string addr port addr port string string bool string string
|
||||
XXXXXXXXXX.XXXXXX CHhAvVGS1DHFjwGM9 127.0.0.1 58246 127.0.0.1 110 pop3_server_command_unknown - F zeek POP3
|
||||
XXXXXXXXXX.XXXXXX CHhAvVGS1DHFjwGM9 127.0.0.1 58246 127.0.0.1 110 pop3_server_command_unknown + F zeek POP3
|
||||
XXXXXXXXXX.XXXXXX CHhAvVGS1DHFjwGM9 127.0.0.1 58246 127.0.0.1 110 line_terminated_with_single_CR - F zeek CONTENTLINE
|
||||
XXXXXXXXXX.XXXXXX CHhAvVGS1DHFjwGM9 127.0.0.1 58246 127.0.0.1 110 too_many_analyzer_violations - F zeek POP3
|
||||
#close XXXX-XX-XX-XX-XX-XX
|
||||
|
|
|
@ -7,11 +7,13 @@ Expr: 18446744073709551612
|
|||
Signed Expr: 4
|
||||
Double -1.23: 1.230000
|
||||
Enum ENUM3: 2
|
||||
Enum in record: 2 2
|
||||
File 21.000000
|
||||
Function add_interface: 2
|
||||
Integer -10: 10
|
||||
Interval -5.0 secs: 5.000000
|
||||
Port 80/tcp: 65616
|
||||
Port in record: 65616 65616
|
||||
Record [i=10, j=<uninitialized>, k=<uninitialized>]: 3
|
||||
Set: 3
|
||||
String 'Hello': 5
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue