CVE-2024-50131 tracing: Consider the NULL character when validating the event length