Improve memory safety with defer for event cleanup across handlers, optimize conditional logging, and bump version to v0.4.3.
Some checks failed
Go / build (push) Has been cancelled

This commit is contained in:
2025-09-11 17:14:50 +01:00
parent 6e06905773
commit 2dd119401b
4 changed files with 79 additions and 37 deletions

View File

@@ -48,6 +48,9 @@ func TestTMarshalBinary_UnmarshalBinary(t *testing.T) {
// Marshal unmarshaled binary event back to JSON
unmarshaledJSON := eb.Serialize()
defer func(ev *E) {
eb.Free()
}(eb)
// Compare the two JSON representations
if !utils.FastEqual(b, unmarshaledJSON) {