3
0
Mirror von https://github.com/ViaVersion/ViaBackwards.git synchronisiert 2024-09-07 21:32:52 +02:00

fix possible array out of bounds

Dieser Commit ist enthalten in:
creeper123123321 2019-03-30 15:08:31 -03:00
Ursprung 1f3ed39eb6
Commit 6f20b874c5
Es konnte kein GPG-Schlüssel zu dieser Signatur gefunden werden
GPG-Schlüssel-ID: 0AC57D54786721D1

Datei anzeigen

@ -39,6 +39,6 @@ public class SoundMapping {
} }
public static int getOldSound(int newSound) { public static int getOldSound(int newSound) {
return newSound >= sounds.length ? -1 : sounds[newSound]; return newSound < 0 || newSound >= sounds.length ? -1 : sounds[newSound];
} }
} }