hyperium / hyperium/hyper

Return an error instead of aborting on panics in C API

Open
#2,397 10 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-ffi C-refactor E-easy
Dominant language
Rust
Stars
16.3k
Forks
1.8k
Avg merge
1d 22h
Merged PRs (30d)
14

Description

The C API will currently abort after catching a panic, for safety reasons. However, we shouldn't abort, but rather catch it and return an error code.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the C API path that catches panics and review how it currently aborts; then trace the error-code convention used by nearby API functions. Done means a caught panic no longer aborts the process and the C API returns an error code, with the behavior covered by the relevant tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, rust
Domain
api
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.