mirror of
https://github.com/2009scape/2009Scape-mobile.git
synced 2026-08-01 14:19:12 -06:00
Fixes a crash that could occur with Java 17
This commit is contained in:
parent
3af22f055b
commit
92fcdae05a
1 changed files with 2 additions and 5 deletions
|
|
@ -910,13 +910,10 @@ public class GLFW
|
|||
@NativeType("GLFWvidmode const *")
|
||||
public static GLFWVidMode.Buffer glfwGetVideoModes(@NativeType("GLFWmonitor *") long monitor) {
|
||||
MemoryStack stack = stackGet(); int stackPointer = stack.getPointer();
|
||||
IntBuffer count = stack.callocInt(1);
|
||||
try {
|
||||
// long __result = nglfwGetVideoModes(monitor, memAddress(count));
|
||||
long __result = memAddress(stack.callocLong(1));
|
||||
GLFWVidMode.Buffer buffer = GLFWVidMode.createSafe(__result, 1);
|
||||
buffer.put(glfwGetVideoMode(monitor));
|
||||
return buffer;
|
||||
long __result = glfwGetVideoMode(monitor).address();
|
||||
return GLFWVidMode.createSafe(__result, 1);
|
||||
} finally {
|
||||
stack.setPointer(stackPointer);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue