Only initialize edge_spacing_func if glfw init succeeds
This commit is contained in:
parent
6adf4f5171
commit
1f1f1f60ac
1 changed files with 1 additions and 1 deletions
|
|
@ -1462,8 +1462,8 @@ glfw_init(PyObject UNUSED *self, PyObject *args) {
|
|||
glfwSetDrawTextFunction(draw_text_callback);
|
||||
#endif
|
||||
get_window_dpi(NULL, &global_state.default_dpi.x, &global_state.default_dpi.y);
|
||||
edge_spacing_func = edge_sf; Py_INCREF(edge_spacing_func);
|
||||
}
|
||||
edge_spacing_func = edge_sf; Py_INCREF(edge_spacing_func);
|
||||
Py_INCREF(ans);
|
||||
return ans;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue