aweinstock314 / rust-clipboard

System Clipboard interfacing library in Rust
Apache License 2.0
365 stars 75 forks source link

fix memory leak on mac os #83

Open Lurk opened 3 years ago

Lurk commented 3 years ago

TLDR version of why:

The Clipboard crate calls NSPasteboard.readObjectsForClasses to get current clipboard content, but not Rust nor Objective C runtime knows who is responsible for freeing memory, so nobody frees it. Surprise!

Lurk commented 3 years ago

This is unfinished stuff. If you are interested, I will push the update.

Finished stuff located here: https://github.com/alacritty/copypasta/pull/33