summaryrefslogtreecommitdiff
path: root/internal/statsengine/syscall.go
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2026-05-13 10:22:29 +0300
committerPaul Buetow <paul@buetow.org>2026-05-13 10:22:29 +0300
commit5856360a696b958a4c5c57cf512c5a04f0cfd66f (patch)
tree16a37002ac98f65429f7089b918b3f12c3047296 /internal/statsengine/syscall.go
parent7c15d6058cf56e8c7801259f1f842a3a010c5f41 (diff)
fix: reject negative and zero -duration flag values with a clear error
A negative or zero -duration was silently accepted, causing the trace context to be cancelled immediately (time.Duration(N) * time.Second with N <= 0 yields a non-positive timeout), so no events were ever captured. parseFromFlagSet now returns an error for Duration <= 0, matching the existing pattern used for -resetTimer validation. Three new tests cover the negative, zero, and valid positive cases. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Diffstat (limited to 'internal/statsengine/syscall.go')
0 files changed, 0 insertions, 0 deletions