From 73ca3bdbb63d4b503ab5e909779cc84fc86ce1a6 Mon Sep 17 00:00:00 2001 From: Camilla Berglund Date: Mon, 22 Oct 2012 00:56:23 +0200 Subject: [PATCH] Fixed order of operations in iconify test. --- tests/iconify.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/tests/iconify.c b/tests/iconify.c index fc3d9fdd..d5544b07 100644 --- a/tests/iconify.c +++ b/tests/iconify.c @@ -95,6 +95,12 @@ int main(int argc, char** argv) GLFWmonitor monitor = NULL; GLFWwindow window; + if (!glfwInit()) + { + fprintf(stderr, "Failed to initialize GLFW: %s\n", glfwErrorString(glfwGetError())); + exit(EXIT_FAILURE); + } + while ((ch = getopt(argc, argv, "fh")) != -1) { switch (ch) @@ -113,12 +119,6 @@ int main(int argc, char** argv) } } - if (!glfwInit()) - { - fprintf(stderr, "Failed to initialize GLFW: %s\n", glfwErrorString(glfwGetError())); - exit(EXIT_FAILURE); - } - if (monitor) { GLFWvidmode mode;