Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • P pipewire-rs
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 21
    • Issues 21
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 8
    • Merge requests 8
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages & Registries
    • Packages & 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
  • PipeWire
  • pipewire-rs
  • Issues
  • #16
Closed
Open
Created Apr 24, 2021 by alberto colombo@albx79Contributor

Safely wrapping `Stream::dequeue_raw_buffer` and `queue_raw_buffer`

My idea was to create a Buffer struct that wraps ptr::NonNull<pw_sys::pw_buffer>.

My doubt is maily about queue_buffer: the doc says that you should return a buffer to the stream it originated from, but it doesn't say what happens if you return it to the wrong stream. Does pipewire detect it and fails somewhat, or does it cause UB? It matters because in the first case we can just leave it up to the user, with a note in the docs. In the other case, however, we need to find a way to associate a buffer with the stream it came from, and ensure it can't be returned to the wrong one.

Assignee
Assign to
Time tracking