code: improve error handling consistency

This commit is contained in:
Isaac Freund
2020-06-26 00:59:31 +02:00
parent 8fc045b445
commit 79bb0accac
11 changed files with 23 additions and 40 deletions

View File

@ -46,8 +46,7 @@ pub fn init(self: *Self, server: *Server) !void {
// This is automatically freed when the display is destroyed
self.wlr_input_inhibit_manager =
c.wlr_input_inhibit_manager_create(server.wl_display) orelse
return error.CantCreateInputInhibitManager;
c.wlr_input_inhibit_manager_create(server.wl_display) orelse return error.OutOfMemory;
self.seats = std.TailQueue(Seat).init();