- FT_Library library;
- FT_Face face;
- if (FT_Init_FreeType(&library))
- throw std::runtime_error("FreeType init failed.");
-
- // Georgia
- if (FT_New_Face(library, "/usr/share/fonts/truetype/msttcorefonts/Georgia.ttf", 0, &face))
- throw std::runtime_error("Face opening failed.");
- if (FT_Set_Char_Size(face, 0, 12 * 64, 96, 96))
- throw std::runtime_error("Size set failed.");
- fonts.push_back(face);
-
- // FreeSerif
- if (FT_New_Face(library, "/usr/share/fonts/truetype/freefont/FreeSerif.ttf", 0, &face)) {
- std::fprintf(stderr, "Warning: Couldn't open FreeSerif, some glyphs might not be available\n");
- } else {
- if (FT_Set_Char_Size(face, 0, 12 * 64, 96, 96))
- throw std::runtime_error("Size set failed.");
- fonts.push_back(face);
+ if (active_tournament.id == -1) {
+ // No active tournament, sleep a second or so and exit
+ conn.await_notification(1, 0);
+ return;