I've learned that atoi() is deprecated

I suppose that's what I get for not keeping track of new C standards
This commit is contained in:
Keith Bowes 2020-02-27 16:58:36 -05:00
parent 089f20980b
commit 24a88ec13a

View file

@ -165,7 +165,7 @@ struct wb_cursor *wb_cursor_create(struct wb_server *server) {
cursor->server = server;
const char *xcursor_size = getenv("XCURSOR_SIZE");
cursor->xcursor_manager = wlr_xcursor_manager_create(getenv("XCURSOR_THEME"), xcursor_size ? atoi(xcursor_size) : 24);
cursor->xcursor_manager = wlr_xcursor_manager_create(getenv("XCURSOR_THEME"), xcursor_size ? strtoul(xcursor_size, (char **) NULL, 10) : 24);
wlr_xcursor_manager_load(cursor->xcursor_manager, 1);
cursor->cursor_motion.notify = handle_cursor_motion;