Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • BIND BIND
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 594
    • Issues 594
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 100
    • Merge requests 100
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • ISC Open Source ProjectsISC Open Source Projects
  • BINDBIND
  • Merge requests
  • !5622

Stop leaking mutex in nmworker and cond in nm socket

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged Ondřej Surý requested to merge 3051-missing-destroy-for-pthread-primitives into main Dec 08, 2021
  • Overview 9
  • Commits 2
  • Pipelines 3
  • Changes 3

On FreeBSD, the pthread primitives are not solely allocated on stack, but part of the object lives on the heap. Missing pthread_*_destroy causes the heap memory to grow and in case of fast lived object it's possible to run out-of-memory.

Properly destroy the leaking mutex (worker->lock) and the leaking condition (sock->cond).

Closes #3051 (closed)

Edited Dec 08, 2021 by Ondřej Surý
Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: 3051-missing-destroy-for-pthread-primitives