cursor-shape: assert lookup succeeded

This commit is contained in:
Daniel Eklöf 2023-06-27 18:40:25 +02:00
parent 803b250652
commit 9155948ac8
No known key found for this signature in database
GPG key ID: 5BBD4992C116573F

View file

@ -25,6 +25,7 @@ cursor_shape_to_string(enum cursor_shape shape)
};
xassert(shape <= ALEN(table));
xassert(table[shape] != NULL);
return table[shape];
}
@ -47,6 +48,7 @@ cursor_shape_to_server_shape(enum cursor_shape shape)
};
xassert(shape <= ALEN(table));
xassert(table[shape] != 0);
return table[shape];
}
#endif