~sircmpwn/hare-dev

hari: Fix crash on surface_leave v1 APPLIED

Willow Barraco: 1
 Fix crash on surface_leave

 1 files changed, 1 insertions(+), 1 deletions(-)
Export patchset (mbox)
How do I use this?

Copy & paste the following snippet into your terminal to import this patchset into git:

curl -s https://lists.sr.ht/~sircmpwn/hare-dev/patches/53871/mbox | git am -3
Learn more about email & git

[PATCH hari] Fix crash on surface_leave Export this patch

The migration to for-loop was incorrect here.

Signed-off-by: Willow Barraco <contact@willowbarraco.fr>
---
 hari/wayland/surface.ha | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hari/wayland/surface.ha b/hari/wayland/surface.ha
index d9240ba..bea60e0 100644
--- a/hari/wayland/surface.ha
+++ b/hari/wayland/surface.ha
@@ -73,7 +73,7 @@ fn surface_leave(
	output: u32,
) void = {
	let surf = user: *surface;
	for (let i .. surf.outputs) {
	for (let i = 0z; i < len(surf.outputs); i += 1) {
		if (surf.outputs[i] == output) {
			delete(surf.outputs[i]);
			break;
-- 
2.45.2
Thanks!

To git@git.sr.ht:~sircmpwn/hari
   50a0105..  master -> master