flux-framework / flux-core

core services for the Flux resource management framework
GNU Lesser General Public License v3.0
159 stars 49 forks source link

libsubprocess: protect against double EOF #6025

Closed chu11 closed 1 month ago

chu11 commented 1 month ago

Problem: A recent fix in the sdexec module corrected a double EOF, which caused the client side to hang when the LOCAL_UNBUF flag was used. The client side hang was due to incorrect counting of closed channels.

Solution: Properly flag that an EOF has been sent to the caller when the LOCAL_UNBUF flag is used, so that multiple EOFs are not reported to users.

codecov[bot] commented 1 month ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 83.28%. Comparing base (e81e8f8) to head (e98fed0).

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #6025 +/- ## ========================================== - Coverage 83.29% 83.28% -0.01% ========================================== Files 518 518 Lines 83514 83514 ========================================== - Hits 69560 69556 -4 - Misses 13954 13958 +4 ``` | [Files](https://app.codecov.io/gh/flux-framework/flux-core/pull/6025?dropdown=coverage&src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=flux-framework) | Coverage Δ | | |---|---|---| | [src/common/libsubprocess/remote.c](https://app.codecov.io/gh/flux-framework/flux-core/pull/6025?src=pr&el=tree&filepath=src%2Fcommon%2Flibsubprocess%2Fremote.c&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=flux-framework#diff-c3JjL2NvbW1vbi9saWJzdWJwcm9jZXNzL3JlbW90ZS5j) | `76.62% <100.00%> (ø)` | | ... and [12 files with indirect coverage changes](https://app.codecov.io/gh/flux-framework/flux-core/pull/6025/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=flux-framework)