1
0
Fork 0
mirror of https://github.com/gwm17/glfw.git synced 2024-11-23 10:48:51 -05:00

Fixed unguarded calls to monitor callback.

This commit is contained in:
Camilla Berglund 2013-06-04 17:42:22 +02:00
parent 3498163da1
commit f9d1a37621
2 changed files with 5 additions and 2 deletions

View File

@ -461,6 +461,7 @@ skills.
* Matt Arsenault * Matt Arsenault
* Keith Bauer * Keith Bauer
* John Bartholomew * John Bartholomew
* Niklas Bergström
* blanco * blanco
* Lambert Clara * Lambert Clara
* Noel Cower * Noel Cower

View File

@ -140,6 +140,7 @@ void _glfwInputMonitorChange(void)
window->monitor = NULL; window->monitor = NULL;
} }
if (_glfw.monitorCallback)
_glfw.monitorCallback((GLFWmonitor*) monitors[i], GLFW_DISCONNECTED); _glfw.monitorCallback((GLFWmonitor*) monitors[i], GLFW_DISCONNECTED);
} }
@ -161,6 +162,7 @@ void _glfwInputMonitorChange(void)
if (j < monitorCount) if (j < monitorCount)
continue; continue;
if (_glfw.monitorCallback)
_glfw.monitorCallback((GLFWmonitor*) _glfw.monitors[i], GLFW_CONNECTED); _glfw.monitorCallback((GLFWmonitor*) _glfw.monitors[i], GLFW_CONNECTED);
} }