mirror of
https://github.com/glfw/glfw.git
synced 2024-11-25 22:14:34 +00:00
Fixed exit codes.
This commit is contained in:
parent
e20ea6b005
commit
bca0283fdd
@ -72,7 +72,7 @@ int main(void)
|
||||
if (!glfwInit())
|
||||
{
|
||||
fprintf(stderr, "Failed to initialize GLFW: %s\n", glfwErrorString(glfwGetError()));
|
||||
exit(1);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
window = glfwOpenWindow(0, 0, GLFW_WINDOWED, "Defaults", NULL);
|
||||
@ -81,7 +81,7 @@ int main(void)
|
||||
glfwTerminate();
|
||||
|
||||
fprintf(stderr, "Failed to open GLFW window: %s\n", glfwErrorString(glfwGetError()));
|
||||
exit(1);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
glfwGetWindowSize(window, &width, &height);
|
||||
@ -99,6 +99,6 @@ int main(void)
|
||||
window = NULL;
|
||||
|
||||
glfwTerminate();
|
||||
exit(0);
|
||||
exit(EXIT_SUCCESS);
|
||||
}
|
||||
|
||||
|
@ -336,7 +336,7 @@ int main(void)
|
||||
if (!glfwInit())
|
||||
{
|
||||
fprintf(stderr, "Failed to initialize GLFW: %s\n", glfwErrorString(glfwGetError()));
|
||||
exit(1);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
printf("Library initialized\n");
|
||||
@ -358,7 +358,7 @@ int main(void)
|
||||
glfwTerminate();
|
||||
|
||||
fprintf(stderr, "Failed to open GLFW window: %s\n", glfwErrorString(glfwGetError()));
|
||||
exit(1);
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
printf("Window opened\n");
|
||||
@ -378,6 +378,6 @@ int main(void)
|
||||
}
|
||||
|
||||
glfwTerminate();
|
||||
exit(0);
|
||||
exit(EXIT_SUCCESS);
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user