Skip to content

examples, tests: terminate the ES_ERROR messages with a newline - #1208

Merged
philljj merged 1 commit into
wolfSSL:masterfrom
ejohnstown:ccb-phase1-4
Aug 28, 2026
Merged

examples, tests: terminate the ES_ERROR messages with a newline#1208
philljj merged 1 commit into
wolfSSL:masterfrom
ejohnstown:ccb-phase1-4

Conversation

@ejohnstown

Copy link
Copy Markdown
Contributor

ES_ERROR() passes its arguments straight to fprintf(stderr, ...), so
a message with no trailing newline runs into whatever the shell or the
test harness prints next.

  • 7 sites in the echoserver, 6 in tests/auth.c, 8 in the Espressif copy
    of the echoserver, which carries the same macro and takes this kind of
    cross-cutting fix (e91ff50, ab8058d)
  • the two wrapped format strings already ended with a newline

Message text only; no logic change.

Copilot AI lite review requested due to automatic review settings August 27, 2026 23:12

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR improves the readability of error output produced by the ES_ERROR() macro by ensuring affected messages end with a trailing newline, preventing stderr output from running into subsequent shell/test-harness text.

Changes:

  • Add \n terminators to ES_ERROR() format strings in tests/auth.c.
  • Add \n terminators to ES_ERROR() format strings in the main echoserver example.
  • Apply the same newline termination fix to the Espressif ESP-IDF echoserver example copy.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
tests/auth.c Ensures ES_ERROR() stderr messages in auth test server thread are newline-terminated.
examples/echoserver/echoserver.c Ensures selected echoserver ES_ERROR() messages are newline-terminated.
ide/Espressif/ESP-IDF/examples/wolfssh_echoserver/main/echoserver.c Mirrors the newline-termination fix in the ESP-IDF echoserver copy.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

ES_ERROR() passes its arguments straight to fprintf(stderr, ...), so a
message with no trailing newline runs into whatever the shell or the
test harness prints next.

- 7 sites in the echoserver, 6 in tests/auth.c, 8 in the Espressif copy
  of the echoserver, which carries the same macro and takes this kind of
  cross-cutting fix (e91ff50, ab8058d)
- the two wrapped format strings already ended with a newline

@wolfSSL-Fenrir-bot wolfSSL-Fenrir-bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fenrir Automated Review — PR #1208

Scan targets checked: wolfssh-bugs, wolfssh-src

Fenrir result: Approved ✅

No new issues found in the changed files.

Advisory only — this automated result does not count as a GitHub approval.

@ejohnstown
ejohnstown requested a review from philljj August 28, 2026 22:31
@philljj philljj self-assigned this Aug 28, 2026
@philljj
philljj merged commit 26ccac3 into wolfSSL:master Aug 28, 2026
165 checks passed
@ejohnstown
ejohnstown deleted the ccb-phase1-4 branch August 28, 2026 23:26
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.

4 participants