Skip to content

Fixed the HTTP client build without packet chaining - #489

Merged
fdesbiens merged 1 commit into
devfrom
fix/web-client-no-packet-chain
Oct 17, 2026
Merged

fdesbiens merged 1 commit into
devfrom
fix/web-client-no-packet-chain

Conversation

@fdesbiens

Copy link
Copy Markdown
Contributor

Problem

The fragmented-header parsing added for #316 (d4ffe44) walks packet chains through
nx_packet_next and nx_packet_last. NX_PACKET has neither member under
NX_DISABLE_PACKET_CHAIN, so addons/web/nx_web_http_client.c stopped compiling in
v4_no_chain_build and v6_no_chain_build. That took the whole netxduo library down in those two
configurations. CI dev has been red on dev since, for example run 38969654639 at 2cd5aa4e.

Change

The three chain walks are now guarded with #ifndef NX_DISABLE_PACKET_CHAIN, the way the rest of
the file already guards them. Without chaining, a packet is a single buffer:

  • _nx_web_http_client_response_header_trim only advances the prepend pointer.
  • The status-prefix copy and the header cursor stop at the end of the first buffer.

With chaining, the preprocessed source is byte-identical to before. This was checked in all three
web configurations.

Verification

netxduo  v4_no_chain_build           builds; 855/855 tests pass
netxduo  v6_no_chain_build           builds; 856/856 tests pass
web      default_build_coverage      56/56
web      no_tls_build_coverage       56/56
web      digest_authenticate_build   56/56

No web client test runs without packet chaining in any suite: the web suite has no no-chain
configuration, and the netxduo suite runs no web tests. So the no-chain path is compiled, not
exercised.

The fragmented-header parsing added for #316 walks packet chains through
nx_packet_next and nx_packet_last, which NX_PACKET does not have under
NX_DISABLE_PACKET_CHAIN. nx_web_http_client.c stopped compiling in
v4_no_chain_build and v6_no_chain_build, and with it the whole netxduo
library in those two configurations.

The three chain walks are now guarded the way the rest of the file guards
them. Without chaining a packet is a single buffer, so the header trim
only advances the prepend pointer, and the status-prefix copy and the
header cursor stop at the end of the first buffer. With chaining the
preprocessed source is byte-identical to before.

Both no-chain configurations build again and their full suites pass, and
every web configuration's suite passes. No web client test runs without
packet chaining in any suite, so the no-chain path is compiled, not
exercised.

Assisted-by: Claude Code (Opus 5.5) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant