mirror of
https://github.com/shadowfacts/lwjgl2-arm64.git
synced 2026-04-03 11:59:40 +02:00
Changed manual null check to a MemoryUtil.getAddressSafe call.
This commit is contained in:
parent
2482d66ea1
commit
84cd3b562b
|
|
@ -93,7 +93,7 @@ public final class ALC11 {
|
|||
*/
|
||||
public static ALCdevice alcCaptureOpenDevice(String devicename, int frequency, int format, int buffersize) {
|
||||
ByteBuffer buffer = MemoryUtil.encodeASCII(devicename);
|
||||
long device_address = nalcCaptureOpenDevice((buffer == null) ? 0 : MemoryUtil.getAddress(buffer), frequency, format, buffersize);
|
||||
long device_address = nalcCaptureOpenDevice(MemoryUtil.getAddressSafe(buffer), frequency, format, buffersize);
|
||||
if(device_address != 0) {
|
||||
ALCdevice device = new ALCdevice(device_address);
|
||||
synchronized (ALC10.devices) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue