From 52a4d3a1e54203c38fbc65345d19f2f1b704adb4 Mon Sep 17 00:00:00 2001
From: Guido Cella <guidocella91@gmail.com>
Date: Sat, 5 Sep 2020 18:29:39 +0200
Subject: use size_t for lengths

---
 dwl.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/dwl.c b/dwl.c
index 6e0bcb9..8ddb24d 100644
--- a/dwl.c
+++ b/dwl.c
@@ -409,7 +409,7 @@ applyexclusive(struct wlr_box *usable_area,
 	edges[3].negative_axis = &usable_area->width;
 	edges[3].margin = margin_right;
 
-	for (unsigned int i = 0; i < LENGTH(edges); ++i) {
+	for (size_t i = 0; i < LENGTH(edges); ++i) {
 		if ((anchor == edges[i].singular_anchor || anchor == edges[i].anchor_triplet)
 				&& exclusive + edges[i].margin > 0) {
 			if (edges[i].positive_axis)
@@ -585,7 +585,7 @@ arrangelayers(Monitor *m)
 			&usable_area, false);
 
 	// Find topmost keyboard interactive layer, if such a layer exists
-	for (unsigned int i = 0; i < nlayers; ++i) {
+	for (size_t i = 0; i < nlayers; ++i) {
 		wl_list_for_each_reverse(layersurface,
 				&m->layers[layers_above_shell[i]], link) {
 			if (layersurface->layer_surface->current.keyboard_interactive &&
@@ -820,7 +820,7 @@ createmon(struct wl_listener *listener, void *data)
 	m->m = *wlr_output_layout_get_box(output_layout, m->wlr_output);
 	m->w = m->m;
 
-	for (unsigned int i = 0; i < nlayers; ++i) {
+	for (size_t i = 0; i < nlayers; ++i) {
 		wl_list_init(&m->layers[i]);
 	}
 }
@@ -1982,7 +1982,7 @@ shouldfocusclients(Monitor *m)
 		ZWLR_LAYER_SHELL_V1_LAYER_OVERLAY,
 		ZWLR_LAYER_SHELL_V1_LAYER_TOP,
 	};
-	for (unsigned int i = 0; i < LENGTH(layers_above_shell); ++i)
+	for (size_t i = 0; i < LENGTH(layers_above_shell); ++i)
 		wl_list_for_each(layersurface, &m->layers[layers_above_shell[i]], link)
 			if (layersurface->layer_surface->current.keyboard_interactive &&
 					!layersurface->unmapping)
-- 
cgit v1.2.3