Skip to content

DAOS-19056 pipeline: fix double-free and potential memory leaks (#18411)#18548

Merged
gnailzenh merged 1 commit into
release/2.8from
shilongw/DAOS-1905-2.8
Jun 30, 2026
Merged

DAOS-19056 pipeline: fix double-free and potential memory leaks (#18411)#18548
gnailzenh merged 1 commit into
release/2.8from
shilongw/DAOS-1905-2.8

Conversation

@wangshilong

Copy link
Copy Markdown
Contributor

Fix several resource management issues in the pipeline code paths:

  • Free client filter parts correctly on dfs_pipeline_create/destroy error paths
  • Keep SGL iov cleanup consistent when kds allocation fails in dfs_readdir_with_filter
  • Fix the server-side pipeline handler to release bulk reply buffers and SGL iov buffers according to ownership, avoiding double-free when data is transferred via RDMA bulk

Also stop returning a positive value from enum_pack_cb to terminate dkey iteration (use VOS_ITER_CB_EXIT instead), and suppress misleading DER_UNKNOWN debug logs for non-error return codes.

Steps for the author:

  • Commit message follows the guidelines.
  • Appropriate Features or Test-tag pragmas were used.
  • Appropriate Functional Test Stages were run.
  • At least two positive code reviews including at least one code owner from each category referenced in the PR.
  • Testing is complete. If necessary, forced-landing label added and a reason added in a comment.

After all prior steps are complete:

  • Gatekeeper requested (daos-gatekeeper added as a reviewer).

Fix several resource management issues in the pipeline code paths:

 - Free client filter parts correctly on dfs_pipeline_create/destroy error paths
 - Keep SGL iov cleanup consistent when kds allocation fails in dfs_readdir_with_filter
 - Fix the server-side pipeline handler to release bulk reply buffers and SGL iov buffers
according to ownership, avoiding double-free when data is transferred via RDMA bulk

Also stop returning a positive value from enum_pack_cb to terminate dkey iteration
(use VOS_ITER_CB_EXIT instead), and suppress misleading DER_UNKNOWN debug logs for
non-error return codes.

Signed-off-by: Wang Shilong <shilong.wang@hpe.com>
@wangshilong wangshilong requested review from a team as code owners June 26, 2026 03:55
@wangshilong wangshilong added the clean-cherry-pick Cherry-pick from another branch that did not require additional edits label Jun 26, 2026
@github-actions

Copy link
Copy Markdown

Ticket title is 'Potential crash using DAOS pipeline '
Status is 'In Review'
https://daosio.atlassian.net/browse/DAOS-19056

@wangshilong wangshilong requested review from knard38 and mchaarawi June 26, 2026 03:56
@gnailzenh gnailzenh merged commit 9007127 into release/2.8 Jun 30, 2026
42 checks passed
@gnailzenh gnailzenh deleted the shilongw/DAOS-1905-2.8 branch June 30, 2026 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

clean-cherry-pick Cherry-pick from another branch that did not require additional edits

Development

Successfully merging this pull request may close these issues.

4 participants