mirror of
https://github.com/gentoo-mirror/gentoo.git
synced 2026-09-24 04:59:14 -07:00
media-video/mpv: backport cpu usage fix with wayland clipboard
Kind of simple, so doing it straight-to-stable. Closes: https://bugs.gentoo.org/959000 Signed-off-by: Ionen Wolkens <ionen@gentoo.org>
This commit is contained in:
16
media-video/mpv/files/mpv-0.40.0-wayland-clipboard-cpu.patch
Normal file
16
media-video/mpv/files/mpv-0.40.0-wayland-clipboard-cpu.patch
Normal file
@@ -0,0 +1,16 @@
|
||||
https://bugs.gentoo.org/959000
|
||||
https://github.com/mpv-player/mpv/issues/16139
|
||||
https://github.com/mpv-player/mpv/pull/16140
|
||||
--- a/player/clipboard/clipboard-wayland.c
|
||||
+++ b/player/clipboard/clipboard-wayland.c
|
||||
@@ -349,4 +349,10 @@
|
||||
return false;
|
||||
|
||||
+ if (fds[2].revents & (POLLERR | POLLHUP | POLLNVAL))
|
||||
+ destroy_offer(wl->selection_offer);
|
||||
+
|
||||
+ if (fds[3].revents & (POLLERR | POLLHUP | POLLNVAL))
|
||||
+ destroy_offer(wl->primary_selection_offer);
|
||||
+
|
||||
if (fds[2].revents & POLLIN)
|
||||
get_selection_data(wl, wl->selection_offer, false);
|
||||
@@ -124,6 +124,10 @@ BDEPEND="
|
||||
wayland? ( dev-util/wayland-scanner )
|
||||
"
|
||||
|
||||
PATCHES=(
|
||||
"${FILESDIR}"/${P}-wayland-clipboard-cpu.patch
|
||||
)
|
||||
|
||||
pkg_pretend() {
|
||||
if has_version "${CATEGORY}/${PN}[X,opengl]" && use !egl; then #953107
|
||||
ewarn "${PN}'s 'opengl' USE was removed in favour of the 'egl' USE as it was"
|
||||
Reference in New Issue
Block a user