From 6bac1bd2576d76de32e79387d9dc7cbb7c9c8e9c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Sun, 3 May 2020 14:17:54 +0200 Subject: [PATCH] term: thrd_success isn't necessarily 0 --- terminal.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/terminal.c b/terminal.c index ab4499e6..1c00e5ae 100644 --- a/terminal.c +++ b/terminal.c @@ -497,7 +497,7 @@ initialize_render_workers(struct terminal *term) int ret = thrd_create( &term->render.workers.threads[i], &render_worker_thread, ctx); - if (ret != 0) { + if (ret != thrd_success) { LOG_ERR("failed to create render worker thread: %s (%d)", thrd_err_as_string(ret), ret); @@ -664,7 +664,7 @@ load_fonts_from_conf(const struct terminal *term, const struct config *conf, thrd_t tids[4] = {}; for (size_t i = 0; i < 4; i++) { int ret = thrd_create(&tids[i], &font_loader_thread, &data[i]); - if (ret != 0) { + if (ret != thrd_success) { LOG_ERR("failed to create font loader thread: %s (%d)", thrd_err_as_string(ret), ret); break; @@ -1365,7 +1365,7 @@ term_font_size_adjust(struct terminal *term, double amount) thrd_t tids[4] = {}; for (size_t i = 0; i < 4; i++) { int ret = thrd_create(&tids[i], &font_size_adjust_thread, &data[i]); - if (ret != 0) { + if (ret != thrd_success) { LOG_ERR("failed to create font adjustmen thread: %s (%d)", thrd_err_as_string(ret), ret); break;