Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove the remaining uses of err(3) #74

Open
haesbaert opened this issue Oct 8, 2024 · 0 comments
Open

Remove the remaining uses of err(3) #74

haesbaert opened this issue Oct 8, 2024 · 0 comments
Labels

Comments

@haesbaert
Copy link
Collaborator

There are some panic calls that maybe we can remove, unwrap the stack and kill the queue, better than killing the program, these are basically extra bug checking so they would only trigger if we screwed up. Still, this is a library, and libraries shouldn't exit.

btf.c:          err(1, "bit offset not multiple of 8");
quark.c:                err(1, "clock_gettime");
quark.c:                err(1, "we got consecutive collisions, this is a bug");
quark.c:                err(1, "collision on pidtime tree, this is a bug");
kprobe_queue.c:         errx(1, "getting an event larger than wrapped buf");
@haesbaert haesbaert added the TODO label Oct 8, 2024
@haesbaert haesbaert added this to the v0.2 milestone Oct 15, 2024
@haesbaert haesbaert removed this from the v0.3 milestone Jan 14, 2025
haesbaert added a commit that referenced this issue Jan 14, 2025
- Bump retries on insert from 10 to 1000 before giving up.
- Put a timeout on drain_for_pid(), I used to manually test the changing paths,
  and it's good to have anyway.
- Check if clock_gettime() works in quark_queue_open(), maybe it gets EPERM due
  to seccomp and whatnot, sanitize return of now64(), program still survives. I
  just don't want to check now64() errors while they're impossible.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant