Fix assertions for glfwSetGamma value

The NaN assert was implicit in the other ones.  The lower bound assert
incorrectly allowed a value of zero.

Related to #1387.
master
Camilla Löwy ago%!(EXTRA string=7 years)
parent 8c611fd5d0
commit 751c6f9a27
  1. 3
      src/monitor.c

@ -431,8 +431,7 @@ GLFWAPI void glfwSetGamma(GLFWmonitor* handle, float gamma)
unsigned short values[256];
GLFWgammaramp ramp;
assert(handle != NULL);
assert(gamma == gamma);
assert(gamma >= 0.f);
assert(gamma > 0.f);
assert(gamma <= FLT_MAX);
_GLFW_REQUIRE_INIT();

Loading…
Cancel
Save