Skip to content

libc/stdio: add tests for flockfile, ftrylockfile, funlockfile#488

Open
julianuziemblo wants to merge 1 commit into
masterfrom
julianuziemblo/RTOS-1334
Open

libc/stdio: add tests for flockfile, ftrylockfile, funlockfile#488
julianuziemblo wants to merge 1 commit into
masterfrom
julianuziemblo/RTOS-1334

Conversation

@julianuziemblo
Copy link
Copy Markdown
Contributor

@julianuziemblo julianuziemblo commented May 22, 2026

YT: RTOS-1334

Description

Motivation and Context

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Chore (refactoring, style fixes, git/CI config, submodule management, no code logic changes)

How Has This Been Tested?

  • Already covered by automatic testing.
  • New test added: (add PR link here).
  • Tested by hand on: ia32-generic-qemu

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing linter checks and tests passed.
  • My changes generate no new compilation warnings for any of the targets.

Special treatment

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces new unit tests for stdio_flockfile and recursive mutex try-lock functionality. Feedback was provided regarding the robustness of the tests, specifically highlighting a busy-wait loop in the stdio_flockfile test that lacks a timeout and a potential deadlock in the multithreaded mutex test where a thread might exit without releasing a previously acquired lock.

Comment thread libc/stdio/stdio_file.c
Comment thread sys/mutex/mutex.c Outdated
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 22, 2026

Unit Test Results

10 598 tests   9 928 ✅  52m 29s ⏱️
   649 suites    670 💤
     1 files        0 ❌

Results for commit 1ca54b0.

♻️ This comment has been updated with latest results.

@julianuziemblo julianuziemblo changed the title libc/stdio: add tests for flockfile, ftrylockfile, funlockfile, sys/mutex: add tests for mutexTry on recursive lock libc/stdio: add tests for flockfile, ftrylockfile, funlockfile May 22, 2026
@julianuziemblo julianuziemblo force-pushed the julianuziemblo/RTOS-1334 branch from 09efe82 to 1ca54b0 Compare May 22, 2026 11:54
@julianuziemblo
Copy link
Copy Markdown
Contributor Author

I split this in 2 PRs: this and #489, to make it more managable and the title shorter

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