• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

OpenCyphal / libcanard
100%

Build:
DEFAULT BRANCH: master
Repo Added 24 Mar 2026 02:11PM UTC
Files 1
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

LAST BUILD ON BRANCH master
branch: SELECT
CHANGE BRANCH
x
  • No branch selected
  • experimental
  • experimental-subscription
  • fix/rx-behavioral-correctness
  • master
  • pavel-kirienko-patch-1

02 Jul 2026 09:13PM UTC coverage: 100.0%. Remained the same
28621970011

push

github

web-flow
Fix RX behavioral defects: reassembly asserts, filter config, callback re-entrancy (#260)

## Summary

v5 TX/RX hardening in two parts. Every fix ships with a regression test
that fails on the pre-fix code and passes after.

### RX behavioral fixes (`canard.c`)

- `rx_subscribe`: accumulate `filters_dirty` (`||`) — a duplicate
subscribe no longer cancels a pending acceptance-filter reconfiguration
(was silent RX loss on filter-capable nodes).
- `rx_session_accept` / `rx_session_complete_slot`: drop the false
`slot->iface_index == ses->iface_index` assert that aborted on valid
redundant-interface traffic (per-slot affinity is still enforced at
admission).
- `rx_parse` (v0 anonymous): route on the 2 low data-type-ID bits per
the DroneCAN spec (the upper bits are a random discriminator), with a
weak HW acceptance filter for v0 DTID ≤ 3 — still one filter entry per
subscription.
- `rx_session_update`: dispatch `on_message` last, so a callback that
unsubscribes itself can't cause a use-after-free.
- `canard_new`: set `filters_dirty = filter_count > 0` so forced
Heartbeat/NodeStatus occupancy filters program even before the first
subscription.
- Forced-filter dedup: replace the alias-prone single-frame probe with a
filter-coverage (subset) test `rx_filter_covered`.

### Available-interfaces bitmap (intentional `canard_new` API break)

`canard_new()` gains an `iface_bitmap` of the interfaces available on
the node, ANDed into every enqueue at the single TX chokepoint
(`tx_push`). Requests/responses and all-publishes no longer queue frames
for interfaces that can't be drained. A **zero** bitmap declares a
**listen-only** node (TX is a clean no-op). Bits beyond
`CANARD_IFACE_COUNT` are rejected. Call sites, the demo, and the README
example are updated.

## Verification

Full suite green in the Debug build (assertions on); `clang-tidy` +
`cppcheck` + `clang-format` clean. Each fix was confirmed to be a real
guard by reverting its hunk and watching the test fail ... (continued)

218 of 218 branches covered (100.0%)

Branch coverage included in aggregate %.

31 of 31 new or added lines in 1 file covered. (100.0%)

880 of 880 relevant lines covered (100.0%)

14657.51 hits per line

Relevant lines Covered
Build:
Build:
880 RELEVANT LINES 880 COVERED LINES
14657.51 HITS PER LINE
Source Files on master
  • Tree
  • List 1
  • Changed 1
  • Source Changed 1
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line Branch Hits Branch Misses

Recent builds

Builds Branch Commit Type Ran Committer Via Coverage
28621970011 master Fix RX behavioral defects: reassembly asserts, filter config, callback re-entrancy (#260) ## Summary v5 TX/RX hardening in two parts. Every fix ships with a regression test that fails on the pre-fix code and passes after. ### RX behavioral fixe... push 02 Jul 2026 09:15PM UTC web-flow github
100.0
28621362151 fix/rx-behavioral-correctness Add per-instance available-interfaces bitmap (canard_new API break) canard_new() now takes an iface_bitmap describing the interfaces available on the node. It is ANDed into the requested interface bitmap at the single TX chokepoint (tx_push), so ... Pull #260 02 Jul 2026 09:04PM UTC pavel-kirienko github
100.0
28606296795 fix/rx-behavioral-correctness Fix RX behavioral defects: reassembly asserts, filter config, callback re-entrancy Adversarial review of the v5 RX pipeline surfaced several behavioral defects, each fixed here with a regression test that fails on the pre-fix code: - rx_subscrib... Pull #260 02 Jul 2026 04:41PM UTC pavel-kirienko github
100.0
27090713836 master Update the v5 version description (#259) push 07 Jun 2026 11:07AM UTC web-flow github
100.0
27090407460 pavel-kirienko-patch-1 Update README for v5.0.alpha API changes Clarified v5.0.alpha section regarding API redesign and intended use case. push 07 Jun 2026 10:54AM UTC web-flow github
100.0
27090296489 pavel-kirienko-patch-1 Change version label to v5.0.alpha Updated version label from 'v5.0 [WORK IN PROGRESS]' to 'v5.0.alpha' in README. push 07 Jun 2026 10:49AM UTC web-flow github
100.0
24084737481 master v5.0 alpha (#258) v5 is a major rework based on the experience gained from extensive production use of the previous revisions. The API has been redesigned from scratch and as such there is no migration guide available; please refer to the example... push 07 Apr 2026 01:48PM UTC web-flow github
100.0
24076783200 experimental Improve the subscription API: return incumbent if exists Pull #258 07 Apr 2026 10:31AM UTC pavel-kirienko github pending completion  
23899682825 experimental-subscription Improve the subscription API: return incumbent if exists push 02 Apr 2026 12:45PM UTC pavel-kirienko github
100.0
23880643122 experimental-subscription improved subscription API push 02 Apr 2026 02:27AM UTC pavel-kirienko github
100.0
See All Builds (22)
  • Repo on GitHub
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc