mirror of
https://github.com/hyprwm/aquamarine.git
synced 2024-11-17 04:56:00 +01:00
wayland: fix possible out-of-range crash in setCursor
This commit is contained in:
parent
ddf6987b53
commit
3989aa9b2f
1 changed files with 2 additions and 1 deletions
|
@ -655,7 +655,8 @@ bool Aquamarine::CWaylandOutput::setCursor(Hyprutils::Memory::CSharedPointer<IBu
|
||||||
if (!buffer) {
|
if (!buffer) {
|
||||||
cursorState.cursorBuffer.reset();
|
cursorState.cursorBuffer.reset();
|
||||||
cursorState.cursorWlBuffer.reset();
|
cursorState.cursorWlBuffer.reset();
|
||||||
backend->pointers.at(0)->pointer->sendSetCursor(cursorState.serial, nullptr, cursorState.hotspot.x, cursorState.hotspot.y);
|
if (!backend->pointers.empty())
|
||||||
|
backend->pointers.at(0)->pointer->sendSetCursor(cursorState.serial, nullptr, cursorState.hotspot.x, cursorState.hotspot.y);
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue